docs(ai): add scoped backend conventions
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
# Backend router
|
||||
|
||||
Объединяй triggers из смысла задачи, путей и обнаруженных boundaries.
|
||||
Читай выбранные guides до решения; якорь допускает чтение только нужного раздела.
|
||||
Просто backend-файл не требует всех conventions.
|
||||
|
||||
| Решение / сигнал | Читать |
|
||||
| --- | --- |
|
||||
| Новый module/provider/service; бизнес-логика; перенос responsibility | [Architecture](conventions/backend-architecture.md) |
|
||||
| Controller, DTO, route/status, validation/exception, публичная HTTP-семантика | [HTTP API](conventions/backend-http-api.md) |
|
||||
| Prisma/schema/query/persistence, transaction, migration, atomic write | [Data](conventions/backend-data.md) |
|
||||
| Тесты или behavior с testing risk | [Testing](conventions/backend-testing.md) |
|
||||
| JWT, cookie, login/refresh/logout, guard/access, token encryption, sensitive logs | [Security](conventions/security-auth.md) |
|
||||
| T-Bank/gRPC/proto, upstream retry/rate limit/cache, MoexClient | [Integrations](conventions/backend-integrations.md) |
|
||||
| Logging/request context без изменения secrets/auth | [Logging](conventions/backend-architecture.md#logging) |
|
||||
| Новый abstraction/dependency, refactor, неясный scope | [Общий выбор реализации](../../docs/development/engineering-governance.md#выбор-реализации) |
|
||||
| Изменение request/response/route/status/error shape или Swagger metadata | HTTP API + [общий contract workflow](../../docs/development/runtime-openapi-verification.md) |
|
||||
|
||||
Новый endpoint обычно требует HTTP API + Testing; Architecture/Data/Security
|
||||
добавляются по новым ответственности, persistence или access rules.
|
||||
Изменение одного Prisma query без HTTP/auth границы не требует HTTP API/Security.
|
||||
Auth refresh активирует Security + Data + Testing; HTTP API добавляется, если
|
||||
меняется controller/HTTP contract. Exact docs/spec sources выбирай через SOURCES.
|
||||
Повтори routing при расширении diff, включая новые и unstaged файлы.
|
||||
Reference in New Issue
Block a user