Connecting OpenTelemetry spans to your analytics SDK or library connects end user and product data back to the underlying production system data. This creates a unified data pipeline allowing your product and engineering teams to work more readily in sync. Example such as adding spans with customer IDs, account type, or segmentation information can give developers directly actionable information that bridges technical performance with customer experience.
What are you looking to do? |
---|
Add new telemetry to your analytics SDK or library |
See example integrations |
The goal here is to bridge the gap between a product-centric view of user analytics data and the engineering-centric view of the production system data, leading to a more coordinated team and better product.
-
Find the OpenTelemetry SDK for the language(s) or framework(s) used by your SDK
-
Import the language-specific OpenTelemetry API and patch your library method(s)
-
Use the OpenTelemetry docs to add spans, metrics, and logs to annotate analytics calls produced by your SDK with more actionable context
- As an example, here the Segement SDK creates an event added to the span for every
track
event so the developer can see relevant analytics metadata.
- As an example, here the Segement SDK creates an event added to the span for every
- Send data from your product to an OpenTelemetry collector that outputs to the console and verify output.
- Optional: verify in an OpenTelemetry production tool of your choice
Make your code usable to as many people as possible! If you're looking for help here, contact us at [email protected]. We'd love to help support you!
These example solutions use plugins to generate metrics, logs or traces by automatically-instrumenting Javascript libaries or frameworks. No change to the underlying library or framework is needed.
Instrumentation Package | Instrumented Package |
---|---|
opentelemetry-plugin-segment-node | analytics-node |