How can Node.js applications be monitored and what tools would you use?

Instruction: Describe approaches and tools for monitoring Node.js applications.

Context: This question assesses the candidate's familiarity with monitoring and performance analysis tools and practices in the context of Node.js applications.

Updated

Official answer available

Read the opening below, then unlock the full answer and practical guidance.

Start with user-visible service objectives: successful requests, latency distributions and availability for important operations. Monitor traffic and errors together so a quiet or failing endpoint does not look healthy merely because its average latency is low.

Collect Node-specific signals such as event-loop delay/utilization, CPU, heap/RSS, garbage collection and active resource pressure. Also monitor connection pools, queue age, database/provider latency and worker restarts. Rising memory is a symptom to investigate, not automatic proof of a leak...

Related Questions