RustyUserHub is a high-performance, RESTful API crafted with Rust and Actix-web for seamless CRUD operations.
- User Management:
- Create, read, update, and delete user records.
- Unique user identification using UUID.
- Concurrency:
- Thread-safe user data management with
Arc
andMutex
.
- Thread-safe user data management with
- RESTful API:
- Standard RESTful routes for user operations.
- Rust: The application is written in Rust.
- Actix-web: Used as the web application framework.
- Serde: For serialization and deserialization.
- UUID: For unique user identification.
- Arc and Mutex: For thread-safe data management.
- Create User: Handles user creation with unique ID generation.
- Get Users: Retrieves a list of all users.
- Get User by ID: Fetches a specific user by their ID.
- Update User: Updates user details for a specific ID.
- Delete User: Deletes a user by their ID.
![Screenshot 2024-05-23 at 1 32 23 PM](https://private-user-images.githubusercontent.com/81951239/333302843-01817017-90bc-4fcb-bbc7-0ac987035fd7.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjE5MzAyOTgsIm5iZiI6MTcyMTkyOTk5OCwicGF0aCI6Ii84MTk1MTIzOS8zMzMzMDI4NDMtMDE4MTcwMTctOTBiYy00ZmNiLWJiYzctMGFjOTg3MDM1ZmQ3LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA3MjUlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNzI1VDE3NTMxOFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTAyNzYxNDFkOTFhZDY3YWIyZTRmODVhYTRjMDIwMmVkODdmMzBkMTQ2ODQ0NGRkYWZkZTlhODY5OTM0ZDFkNzYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.3tikwXTN8GPw4Q0hU5XcPB5UNxaGHRB9QgxQF_upF1Y)
![Screenshot 2024-05-23 at 1 36 08 PM](https://private-user-images.githubusercontent.com/81951239/333302885-9e287e2d-17fc-410b-8d47-6bf93264e101.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjE5MzAyOTgsIm5iZiI6MTcyMTkyOTk5OCwicGF0aCI6Ii84MTk1MTIzOS8zMzMzMDI4ODUtOWUyODdlMmQtMTdmYy00MTBiLThkNDctNmJmOTMyNjRlMTAxLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA3MjUlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNzI1VDE3NTMxOFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTRlNTIxZThiNzEwYmQ2MGQ2NTNlNDc5NmI3YWZmZDZhZWMwN2Y5ZDEzMmY4M2E5NTQ0MjlkMzFhNzdkNThiMjEmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.312_pSgOQQ5d84GivQMeAwNfVnFlq-a3LOMCPTTCuHY)
The project consists of the following main files:
main.rs
: This is the main Rust file containing the implementation of the RESTful API routes and handlers.Cargo.toml
: This file contains the dependencies and metadata for the Rust project.
To get started with this project:
- Clone the repository.
- Navigate to the project directory.
- Build the project using
cargo build
. - Run the server with
cargo run
.
This project serves as a practical example of implementing a RESTful API in Rust using Actix-web. It demonstrates various concepts such as concurrency, unique identification, and standard RESTful operations in a real-world scenario.
Contributions to this project are welcome. Please fork the repository and create a pull request with your changes.