Integrating with OpenTelemetry traces
Support OpenTelemetry definitions for traces
Instana can seamlessly integrate with OpenTelemetry traces. Instana correlates OpenTelemetry traces with the Instana-generated traces that use the default W3C Trace Context.
Instana supports frequently used definitions in the OpenTelemetry Trace Semantic Conventions and Resource Semantic Conventions. Instana supports the following attributes that are defined in the OpenTelemetry Semantic Conventions.
Span attributes:
- peer.service
- net.peer.ip
- net.peer.name
- net.peer.port
- http.method
- http.url
- http.scheme
- http.host
- http.target
- http.status_code
- http.route
- http.user_agent
- db.system
- db.user
- db.statement
- db.operation
- db.name
- db.connection_string
- messaging.system
- messaging.operation
- messaging.destination
- rpc.system
- rpc.service
- rpc.method
- faas.execution
- faas.trigger
- faas.coldstart
Resource Attributes:
- service.name
- service.instance.id
- container.id
- process.pid
- telemetry.sdk.language
- host.name
- host.id
- cloud.provider
- faas.id
- device.id
- process.runtime.version
- container.name
- container.runtime
- container.image.name
- container.image.tag
- faas.version
Analyzing OpenTelemetry calls
OpenTelemetry is integrated with Instana's AutoTrace technology. If OpenTelemetry is enabled, spans of a trace that is generated by applications are handled in the same way as the spans that come from the Instana tracers.
To filter calls from OpenTelemetry, set the filter query to the OpenTelemetry resource attributes, service.name
and is present
. Set this filter query because the OpenTelemetry specification for resource semantic conventions requires the OpenTelemetry resource attribute service.name
. OpenTelemetry has various ways to specify the service name. For more information, see the OpenTelemetry official documentation.
Every OpenTelemetry attribute or resource attribute is represented with the following tags:
-
Dynamic tags: These tags are calculated from all the OpenTelemetry attributes that are sent to Instana and are present in the call tags catalog. You can easily search the dynamic tags by name, such as
http.method
, directly from the tag catalog. The number of dynamic tags that are put into the tag catalog is limited to 500 different attribute names. If you exceed this limit, use only the static tags to filter and group because they don't have this limitation. -
Static tags: These tags provide access to all the OpenTelemetry attributes or the OpenTelemetry resource attributes that are sent to Instana. To filter or group by static tags, you must first select OpenTelemetry Tag or OpenTelemetry Resource Tag and then specify the attribute name as its key.
If you exceed the limit of 500 OpenTelemetry attributes, review your naming convention for your custom OpenTelemetry attributes. For example, if you want to track A/B testing, instead of creating a new attribute for every user, such as user-123-ab-test=a
,
you can use the two attributes, user-id=123
and ab-test=a
. By using two separate tags, you can easily filter or group your data while you keep the total number of different OpenTelemetry tags low.
Known limitations
- Instana does not support OpenTelemetry span links.
- Instana does not support combining the Instana default context propagator with context propagators other than W3C Trace Context. W3C Trace Context is the default context propagator of OpenTelemetry.