- Update flagship project header in `README.md` to BiteTrack Backend v2 and add the reboot mission statement - Rename the portfolio project limit constraint in `todo.md` to Bitetrack Backend v2 under the core rules - Adjusted archtecture documentation to highlight a production-grade reboot of the legacy system using FastAPI - Refactor title and introductory text to align the project README with the new Bitetrack reboot scope - Update the daily journal entry to match the new naming
23 lines
1.0 KiB
Markdown
23 lines
1.0 KiB
Markdown
# Flagship Project Architecture
|
|
|
|
## Name: BiteTrack Backend v2
|
|
A production-grade reboot of the BiteTrack system focusing on inventory, order management, and core transactional processes using FastAPI.
|
|
|
|
## Core Architectural Layout
|
|
The system follows a layered architecture to decouple routing, validation, business rules, and database access.
|
|
|
|
```mermaid
|
|
graph TD
|
|
Client[Client / curl] -->|HTTP Request| Routers[FastAPI Routers]
|
|
Routers -->|Pydantic Validation| Schemas[Pydantic Schemas]
|
|
Routers -->|Service Call| Services[Business Services]
|
|
Services -->|Query / Mutate| DB[SQLAlchemy Models]
|
|
DB -->|Read/Write| Postgres[(PostgreSQL Database)]
|
|
```
|
|
|
|
## Layers:
|
|
1. **Routers (`routers/`)**: Handles HTTP routing, status codes, and security dependency injections.
|
|
2. **Schemas (`schemas/`)**: JSON serialization, deserialization, and strict input/output verification.
|
|
3. **Services (`services/`)**: Orchestrates business actions, processes transactions, and wraps DB actions.
|
|
4. **Models (`models/`)**: Represents relational tables mapped to PostgreSQL.
|