-
Notifications
You must be signed in to change notification settings - Fork 0
docs: add observability and logging architecture section to operations design spec #563
Copy link
Copy link
Closed
Labels
prio:lowNice to have, can deferNice to have, can deferscope:smallLess than 1 day of workLess than 1 day of workspec:architectureDESIGN_SPEC Section 15 - Technical ArchitectureDESIGN_SPEC Section 15 - Technical Architecturetype:docsDocumentation workDocumentation work
Description
Summary
The operations design spec (docs/design/operations.md) has no dedicated section for the observability/logging architecture. The logging system is comprehensive (7+1 sinks, structured JSON, rotation, redaction, correlation tracking, per-logger routing) but undocumented in the design spec. Observability is only mentioned in passing (audit logging in security sections, error taxonomy in coordination).
Scope
Add a new section to docs/design/operations.md covering:
- Sink layout: The 8 default sinks (console + 7 files), their levels, formats, and logger name routing
- Log file locations:
/data/logs/in Docker,logs/locally, configurable viaSYNTHORG_LOG_DIR - Rotation policy: RotatingFileHandler (10MB x 5 backups) vs WatchedFileHandler (external logrotate)
- Sensitive field redaction: Automatic sanitization of passwords, tokens, API keys, credentials at all nesting depths
- Correlation tracking:
request_id,task_id,agent_idvia async-safe contextvars, injected into every log event - Per-logger levels: Default levels per domain module, configurable overrides
- Event taxonomy: 54 domain-specific event constant modules under
observability/events/ - Uvicorn integration: How Uvicorn access/error logging is routed through structlog
- Docker logging: Container-level json-file driver rotation vs app-level file rotation
- Runtime settings:
root_log_levelandenable_correlationruntime-editable settings
Acceptance Criteria
- New section in
docs/design/operations.mdwith all 10 topics above - References the code conventions in CLAUDE.md (get_logger, structured kwargs, event constants)
- Includes a table of all sinks with level, format, routing, and file path
- Cross-references the existing security audit logging discussion
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
prio:lowNice to have, can deferNice to have, can deferscope:smallLess than 1 day of workLess than 1 day of workspec:architectureDESIGN_SPEC Section 15 - Technical ArchitectureDESIGN_SPEC Section 15 - Technical Architecturetype:docsDocumentation workDocumentation work