[feat] setup master from fork with fastapi + otel
This commit is contained in:
parent
597eae9b97
commit
1fbf77f879
8 changed files with 310 additions and 1 deletions
16
docs/004-versioned-http-api.md
Normal file
16
docs/004-versioned-http-api.md
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
# 004 Versioned HTTP API
|
||||
|
||||
Context
|
||||
- The template needs explicit API versioning and an HTTP boundary that can be replaced later.
|
||||
- FastAPI is the initial framework, but it must not become a hard dependency for core logic.
|
||||
|
||||
Decision
|
||||
- Place HTTP transport code under `adapter/http/fastapi/`.
|
||||
- Mount routers under `/api/v1` and keep version-specific routers in `routers/v1/`.
|
||||
- Map HTTP requests to usecase calls through thin dependencies and handlers only.
|
||||
- Keep framework-specific request and response models in the HTTP adapter layer.
|
||||
|
||||
Consequences
|
||||
- New API versions can be introduced without changing usecase contracts.
|
||||
- Replacing FastAPI means rewriting only the HTTP adapter.
|
||||
- Domain and usecase layers remain free from transport concerns.
|
||||
Loading…
Add table
Add a link
Reference in a new issue