During an incident, a trace shows a 1.8 s gap with no spans between the API and the database call. What do you investigate?
AdvancedScenarioObservability & Telemetry Decisions
Answer
Situation read → A gap means time was spent in code or waiting on something not instrumented: a connection pool queue, a lock, GC, thread pool starvation, or DNS.
What I'd do →
- Check connection pool metrics around the time (HikariCP
hikaricp_connections_pending,pool wait time). - Check GC pauses and CPU throttling on the pod (
container_cpu_cfs_throttled_periods_total). - Check thread pool/event loop metrics (executor queue depth, Node.js event loop lag).
- Use a continuous profiler (Pyroscope, Parca) for the same time window to see where CPU or wall time went.
- Add spans around pool acquisition and outbound DNS lookups so the gap becomes visible next time.
Why → Traces only show what is instrumented; gaps point at resource waiting inside the process.
Interview tip → Mention continuous profiling as the fourth signal next to metrics, logs and traces.
More on Observability & Telemetry Decisions
Your team has metrics and logs but no tracing. A request to checkout fans out to 9 services and nobody can tell where the 2 seconds go. How do you introduce tracing?IntermediateThe monthly observability bill doubled in two months and finance wants it cut by 40%. What do you do?IntermediateA developer adds `customer_id` as a label to a request counter "for better debugging". You catch it in code review. What do you say?BeginnerYou need to pick a trace sampling strategy for a service doing 20,000 requests per second.AdvancedEvery team has built their own Grafana dashboards with different panels. During incidents, nobody can find anything.BeginnerA service's logs are unstructured strings like `Order 123 failed for user 9 after 3 retries`. Searching them during incidents is painful.Beginner