feat(logging): implement structured JSON logging with pino and multi-module context#124
Conversation
…dule context, and redactions
|
@Bilalishaq7 is attempting to deploy a commit to the Jaja's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
Nice Implementation @Bilalishaq7 |
Thanks @devJaja! The backend CI checks are all green, but the Vercel check is waiting on team authorization since this PR is submitted from an external fork. Whenever you get a chance to authorize the Vercel build or merge, it's all ready on my end! |
|
@Bilalishaq7 Resolve the conflicts |
I'm aware, I mean your should resolve the conflicts on your branch |
…dule context, and redactions
Closes #110
Summary
Upgraded the logging infrastructure from standard text-based console outputs to highly efficient, structured JSON telemetry using
pino. This establishes a robust, production-grade observability foundation that makes log data easily parseable and searchable while maintaining high execution performance.Changes
src/utils/logger.ts): Built the core configuration utilizingpinofor production JSON outputs andpino-prettyfor clean local development console logs, controlled dynamically viaNODE_ENV.*.token,*.secret,*.apiKey,*.password) to prevent credential leakage in log aggregation systems.src/agents/base/BaseAgent.ts): Retrofitted the abstract base class with a protected child logger. All specialized sub-agents now automatically inherit and attach runtime metadata (module,agentClass,agentId,capability) to every log line without code duplication.src/coordinator/index.ts&src/index.ts): Injected context-scoped child loggers into the core application server entry point and the deterministic DAG task decomposition engine to cleanly map task allocations.Testing
npm run build.Related Issue
Fixes the lack of structured observability and production-ready trace formats in the backend architecture.
Checklist