/ActixWeb-Step-by-Step-Example

This is a series of tutorials about Actix, step by step to learn how to use the Actix web framewrok programming framework to build applications

Primary LanguageRustApache License 2.0Apache-2.0

📚 Overview

Rust is a new language, loved by programmers. This series of codes is an Actix tutorial that I have summarized and refined based on my personal experience and other books, blogs, etc. And I record some of the code here in my free and spare time. Readers need to have a certain Rust language foundation and web application development foundation. Follow this tutorial step by step and you will definitely gain something.

🎯 Basic01

  • 📍 Demo1

    • The usage of actix runtime
    • The usage of actix HttpResponse
    • How to quickly start an app by HttpServer
    • How to use the app builder chain
  • 📍 Demo2

    • The usage of actix ServiceConfig
    • How to manage the views
    • How to use the default service
  • 📍 Demo3

    • How to start two server
    • How to join the future
  • 📍 Demo4

    • How to use the app data
  • 📍 Demo5

    • How to set cookie in the Response
    • How to render static file
  • 📍 Demo6

    • How to serialize the response data
    • How to obey to rest style

🎯 Basic02

  • 📍 Demo1

    • How to use the Extractor
    • How to use the Serializer and Deserializer to JSON
    • How to use the temporary file as storage
    • How to use Trait for code DRY
    • How to manage the mod
  • 📍 Demo2

    • Start redis instance with Docker
    • How to use the redis pool
    • how to use the env file
    • how to use the Generic to code for DRY
    • How to use the Redis Commands
  • 📍 Demo3

    • Start postgres instance with Docker
    • How to use ORM Model
    • How to use ORM CRUD Commands

🎯 Basic03

  • 📍 Demo1

    • How to Render the html
  • 📍 Demo2

    • How to use javascript to control the behavior of the page
  • 📍 Demo3

    • How to use css to control the layout of the page

🎯 Basic04

  • 📍 Demo1

    • How to use JWT
    • How to encrypt the password
    • How to custom Error
  • 📍 Demo2

    • The user login and set jwt token
      • Modify the user login/logout api
      • Modify the user login/logout html
      • Modify the user login/logout js script
  • 📍 Demo3

    • The user authentication
      • Modify the main.js
      • Modify the main.rs with authentication middleware

🎯 Basic05

  • 📍 Demo1

    • Unit Test for the components
  • 📍 Demo2

    • Integration Test for the API

🎯 Basic06

  • 📍 Demo1

    • Deploy with Docker
    • Use Docker Compose
  • 📍 Demo2

    • Deploy with Docker
    • Use Nginx for LB
    • Use Supervisord to manage processes
  • 📍 Demo3

    • Deploy with Docker
    • Use Nginx for LB
    • Use Docker Compose manage container
  • 📍 Demo4

    • Deploy with Docker
    • Use Nginx for LB
    • Use Keepalive for HA Nginx