Hacker News new | ask | show | jobs
by romed 2782 days ago
"Open tracing" is a bit too opinionated by be universally useful. For example opentracing makes sampling decisions at the end of the span, not the beginning. Because of this you always pay the cost of span annotations even though the vast majority of spans are discarded. I think it's interesting that opentracing descends from the author of Dapper, and opencensus is from Google itself, and yet they've diverged on this and other details. Google of course just uses Dapper.
2 comments

OpenTracing doesn’t actually specify when a span is sampled. IIRC Lightstep sends all spans to a service that makes sampling decisions based on moving latency percentiles, while Jaeger works as you described, sampling in the client. Its implementation specific.
We also use census for a variety of tasks, mainly for metrics but also for propagating small tags from task to task. The tags [1] can be essentially thought of as request-local scoped state for the entire tree of requests.

The presence of these tags can be used to control behavior if you're clever about it.

[1] https://opencensus.io/tag/