postgres=# select * from sessions where video_id = '3Gtuc2lnnsE';
Wait-event tracing, part 1
pg_wait_tracer, core timing, USDT probes, and observer-effect trade-offs.
session summary
Dmitri Fomin demonstrated pg_wait_tracer, an eBPF-based tool that captures every Postgres wait-event transition with microsecond-to-nanosecond timestamps, replayable trace files, latency heatmaps, and query drill-down. The motivating case was intermittent primary-key lookups jumping from milliseconds to a one-second timeout. The group identified inlined pgstat_report_wait_start/end calls as the obstacle to ordinary probes, produced a small USDT-probe prototype, and planned worst-case overhead benchmarks before proposing always-on core instrumentation.
timecodes
- ASH, wait-event gaps, and pg_wait_tracer
- The intermittent one-second query mystery
- Sampling versus complete wait tracing
- Finding a trace path with hardware watchpoints
- Live ASH-style trace visualization
- Latency heatmaps and source-code attribution
- Transition chains for root-cause analysis
- USDT probes, core patch, and benchmark plan