4 ms·
I'm working on a project where I'm handling simultaneous connections to a bunch of peers. What's the best way to log messages to trace the flow of requests thro
by arjvik 4y ago
I'm working on a project where I'm handling simultaneous connections to a bunch of peers. What's the best way to log messages to trace the flow of requests through my system when multiple code paths are running asynchronously (NodeJS, so I can't simply get a thread ID)?
- Groxx 4y agoWith tracing libraries, e.g. https://opentracing.io/ https://opentracing.io/
- viraptor 4y agoThat and some backend... most are SaaS though. The only self hosted one I know of is Grafana Traces/Tempo. I mean, you can just log the trace/span/parent IDs for each request, but that's a bit painful to deal with later.
- ilyt 4y agojaeger + opentracing/opentelemetry libs are easy enough. When testing Jaeger can just work as in-memory database, or put it to some other storage like elasticsearch