Menu

NestJS Error Tracking: 3 Production Filter and Interceptor Boundaries Explained
πŸ“°

NestJS Error Tracking: 3 Production Filter and Interceptor Boundaries Explained

DEV Community: nestjsΒ·XanderCross2748Β·11 days ago
#IeWbQmZw
#devtonestjs#devto#dev#error#exception
Long article (2523 words) β€” no AI summary yet.
Reading 0:00
15s threshold

TL;DR: For a production Node.js customer support agent, use a NestJS exception filter for HTTP failures, an interceptor for request timing, and explicit wrappers for cron jobs and workers. Add process-level handlers as a final failure boundary. Keep latency and cost observations separate from exception counts. A rejected request, a failed agent step, and a process crash need different responses.

Start with signal quality. If one failed support-agent step produces three identical reports, the dashboard gets louder without explaining more. If a scheduled job never starts, exception capture alone cannot tell you it is missing.

How should a NestJS filter and interceptor capture HTTP exceptions?

Before: every catch block writes a stack trace, the interceptor writes another, and the HTTP filter writes a third. A support request looks like several incidents.…

Continue reading β€” create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.