This microservice, BurgasBusMS, is a backend API that wraps the BurgasBusAPI. Built using Rust with the Actix-web framework, it handles requests related to real-time public transport data, such as bus schedules, routes, and current locations. This service is a key part of the real-time transport tracking system that powers the Wise (Legacy) frontend.
Part of the project that won 1st place at the PHEE TECH Hackathon.
- Handles real-time transport data retrieval and processing
- CORS support for frontend communication
- Asynchronous requests with Tokio for improved performance
- Integrated with external APIs (e.g., TransportBurgas) via Reqwest
Rust, Actix-web, Tokio, Reqwest, Serde, Chrono
-
Install dependencies:
cargo build
-
Start the microservice:
cargo run
-
Monitor logs:
- Logs are handled by env_logger. Ensure the
RUST_LOGenvironment variable is set for different log levels.
Example:
export RUST_LOG=info cargo run - Logs are handled by env_logger. Ensure the
The microservice will be accessible at http://localhost:8080 by default.
The microservice handles API requests through Actix-web endpoints, processes them, and communicates with external services using Reqwest. The service exposes endpoints for fetching transport data, bus routes, and live updates.
- The microservice includes unit tests to ensure data processing and API communication work correctly. You can run tests using
cargo test.
You can also explore the frontend of this project here: WiseFrontendLegacy.