The IBM® Instana® platform is a great APM tool with all important capabilities to provide end-to-end observability and AIOps to the companies. The Instana platform can instrument the applications automatically using the one-agent concept where, with a single agent, it can instrument all kinds of applications.

So, why do I need to instrument an application using OpenTelemetry (Otel)? We have some good reasons why, and this example is just because the application is hosted on IBM® Cloud Foundry where we can’t install any agent. In this kind of situation, we have two options to instrument the application.

The first one is to use Instana manual instrumentation and the second one is to use Otel instrumentation and send the tracing to the Instana backend. And, in this example, we’ll use Otel to do it.

Now we can instrument the application using the Otel instructions located on the Otel documentation for Python: Python OpenTelemetry Instrumentation.

Let me show in more detail how the application was instrumented.

Otel packages to be installed:

OpenTelemetry exporters to be configured:

OpenTelemetry instrumentation variables:

Imports required:

Initializing trace provider:

Creating span for tracing:

Adding custom attributes to span:

Instana backend to receive the tracing data:

Now, with those configurations, the Instana backend will start to receive the tracing data.

Let me share some Instana screenshots to demonstrate how to get the data.

Span generated by Otel:

This span is created by Otel. You can see here a custom attribute defined on the code: amsSite.

Error call details collected by Otel:

Application error detected by the Instana platform.

Tracing details:

Application view:

Custom dashboards created using Otel data:

Chart analysis for calls overview calls, erroneous call rate, latency:

You can see here the number of calls, the error rate and latency collected by Otel.

List of traces captured:

This screenshot represents the traces generated by the application through Otel instrumentation.

Individual trace details:

It’s an individual trace created by Otel instrumentation. OpenTelemetry HTTP and custom tags:

Here you can see the custom attributes defined on the instrumentation.

Get started

Ready to try out IBM Instana and see what it can do for you?

Sign up for a free, two-week trial


More from IBM Instana

In observability, “automation” is spelled I-N-S-T-A-N-A

3 min read - Modern application environments need real-time automated observability to have visibility and insights into what is going on. Because of the highly dynamic nature of microservices and the numerous interdependencies among application components, having an automated approach to observability is essential. That’s why traditional solutions like New Relic struggle to keep up with monitoring in cloud-native environments.  Automation in observability is a requirement When an application is not performing properly, customers are unhappy and your business can suffer. If your observability…

Debunking observability myths – Part 6: Observability is about one part of your stack

3 min read - In our blog series, we’ve debunked the following observability myths so far: Part 1: You can skip monitoring and rely solely on logs Part 2: Observability is built exclusively for SREs Part 3: Observability is only relevant and beneficial for large-scale systems or complex architectures Part 4: Observability is always expensive Part 5: You can create an observable system without observability-driven automation Today, we're delving into another misconception about observability—the belief that it's solely applicable to a specific part of your stack or…

Observing Camunda environments with IBM Instana Business Monitoring

3 min read - Organizations today struggle to detect, identify and act on business operations incidents. The gap between business and IT continues to grow, leaving orgs unable to link IT outages to business impact.  Site reliability engineers (SREs) want to understand business impact to better prioritize their work but don’t have a way of monitoring business KPIs. They struggle to link IT outages to business impacts because data is often siloed and knowledge is tribal. It forces teams into a highly reactive mode…

Buying APM was a good decision (so is getting rid of it)

4 min read - For a long time, there wasn’t a good standard definition of observability that encompassed organizational needs while keeping the spirit of IT monitoring intact. Eventually, the concept of “Observability = Metrics + Traces + Logs” became the de facto definition. That’s nice, but to understand what observability should be, you must consider the characteristics of modern applications: Changes in how they’re developed, deployed and operated The blurring of lines between application code and infrastructure New architectures and technologies like Docker,…