spandex-project / spandex

A platform agnostic tracing library
MIT License
333 stars 53 forks source link

Add Service Version Support #122

Closed kamilkowalski closed 2 years ago

kamilkowalski commented 3 years ago

Follow up to #121. Adds support for configuring a service version in tracer options, which can be used for tracking service deployments and their performance regressions. Propagates service_version to all spans, so that later it can be used by the adapter.

The name comes from https://github.com/DataDog/dd-trace-py/pull/1222 - I thought it makes more sense than simply version, as it might be misinterpreted as the tracer module version.

I have a compatible change to https://github.com/spandex-project/spandex_datadog ready here: https://github.com/kamilkowalski/spandex_datadog/commit/300d22ad81396df5f4d01956dcb6bca9b123ba1f. I'll open a PR if and when this one is merged and released I guess - the spandex dep would need to be updated in spandex_datadog first.

Worth checking:

kamilkowalski commented 3 years ago

FWIW here's a demo of the "requests by version" graph in Datadog, produced using both of my changes:

Screenshot_2020-10-25 refresh (env kamil-local) Datadog(1)

dynaum commented 2 years ago

Is there any possibility to merge this PR in a short time? I would love to use the service_version parameter.

GregMefford commented 2 years ago

Sorry this took so ridiculously long to get merged! 😅 And thanks for taking the time to open a PR! 🚀