refactor!: simplify runtime coordination #7
Keep financial ownership, atomic publication and refresh CAS. Failed refresh leaves cookies untouched; logout still clears them. Remove full-history candle prefetch and special metadata retries. Use native Pino request context instead of parallel middleware. BREAKING CHANGE: remove investment stateVersion, queued sync state, and tbank-sync status progress/resources. Consumers must observe resources through sync=observe with the updated frontend contract.
This commit is contained in:
@@ -7,10 +7,12 @@
|
||||
- `info` — значимый lifecycle/outcome; `debug` — подробности успешного RPC;
|
||||
`warn` — восстановимая проблема/retry; `error` — окончательный сбой.
|
||||
Не добавляй log на каждый вход/выход функции или дубликат HTTP completion.
|
||||
- RequestContextService и request middleware владеют correlation: серверный
|
||||
request ID возвращается как `X-Request-ID`, входящий client ID хранится отдельно.
|
||||
- Native `nestjs-pino` context и `pino-http` completion владеют correlation:
|
||||
server request ID возвращается как `X-Request-ID`, client ID хранится отдельно.
|
||||
Настройки принадлежат `common/logging/logging.module.ts`; второй AsyncLocalStorage
|
||||
или HTTP completion middleware не нужен.
|
||||
Передавай существующий context, не создавай собственный UUID в каждом service.
|
||||
- Wrapper ограничивает поля, Pino redacts request secrets. Не логируй passwords,
|
||||
- StructuredLogger ограничивает поля, Pino redacts request secrets. Не логируй passwords,
|
||||
tokens, cookie, Authorization, credentials, connection generation, raw body
|
||||
или upstream error. Secret в `message/stack` не становится безопасным из-за
|
||||
allowlist; правила [Security](security-auth.md) обязательны для sensitive data.
|
||||
|
||||
Reference in New Issue
Block a user