Skip to content

[BACKEND] Add request IDs and structured JSON logging across API and workers #219

@utksh1

Description

@utksh1

Problem

SecuScan needs a production-grade improvement in this area: Observability..

Scope

Generate or accept X-Request-ID, attach it to logs/audit/task records, and produce structured logs suitable for ingestion.

Acceptance Criteria

  • The implementation is focused and does not introduce unrelated UI, docs, lockfile, or formatting churn.
  • Security-sensitive behavior has explicit negative tests where applicable.
  • Existing tests continue to pass, and new tests cover the main success and failure paths.
  • Documentation or configuration examples are updated when operator behavior changes.

Verification

Tests should verify request IDs propagate from API request to background task and audit log.

Difficulty

Hard, useful issue intended for experienced contributors.

Metadata

Metadata

Assignees

Labels

area:backendBackend API, database, or service worklevel:advanced55 pts difficulty label for advanced contributor PRspriority:mediumImportant issue with normal urgencytype:devopsDevOps or infrastructure work category bonus labeltype:featureFeature work category bonus label

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions