azure-sdk-for-python
azure-sdk-for-python copied to clipboard
GA OpenTelemetry tracing plugin
We have a partner ask to GA OTel tracing plugins across all languages in [Zn], this is an uber-issue to track python work in this space. Here're the sub-tasks:
-
Support telemetry schema versioning (attribute names). User should be able to set OTel schema version from an enum we provide and OTel plugin should map attribute names according to given version. OTel schema version
- Set it on tracer's instrumentation scope
- Support 1.12.0 initially only (TBD - will switch to latest by GA)
- Map attribute names reported by SDKs to corresponding ones in configured schema version. Here's the current list https://github.com/lmolkova/azure-sdk/blob/main/docs/tracing/distributed-tracing-conventions.yml
- We'll add new versions every once in a while and users will be able to configure them.
- Don't change attribute names in SDKs
- [nice-to-have] Set client library name and version on tracer instrumentation scope
-
[ ] Cleanups and breaking changes
- AMQP Propagate context using
traceparentandtracestatein addition toDiagnostic-Id - AMQP: When processing single message, use parent-child relationships instead of links
- AMQP: Settlement instrumentation (if not done)
- Nested logical spans suppression by default (new guidelines) "When client method creates a new span and internally calls into other public client methods of the same or different Azure SDK, spans created for inner client methods MUST be suppressed, their attributes and events ignored. Nested spans created for REST calls MUST be the children of the outer client call span. Suppression is generally done by Azure Core."
- https://github.com/Azure/azure-sdk-for-python/issues/9256
- https://github.com/Azure/azure-sdk-for-python/issues/9079
- https://github.com/Azure/azure-sdk-for-python/issues/19573
- AMQP Propagate context using
-
[ ] Testing
- User study if we can find someone internal
- Integration tests for AMQP SDKs, retries, attributes
- Perf testing: e.g. run storage perf tests with tracing enabled.
- Sample will latest and greatest OTel and AppInsights SDK/AzMon exporter including AMQP and HTTP SDK. - Here's the existing draft https://github.com/lmolkova/azuresdk_tracing_demo/tree/python
-
[ ] Misc
- Update docs
- Add tracing to common TSG
Label prediction was below confidence level 0.6 for Model:ServiceLabels: 'Monitor - Exporter:0.33717316,Event Hubs:0.15609778,Service Bus:0.096411765'
Can Set client library name and version on tracer instrumentation scope be scoped into the GA milestone as a must have? It would be great we knew on the span level (populated by tracer instrumentation scope) which azure-sdk service was responsible for generating it. @pvaneck would this be a lot of work?