Beginning with Dynatrace OneAgent v1.133, we now provide support for deep monitoring of C++ and other native language applications on Linux x86 and Windows.
Dynatrace OneAgent SDK for monitoring C/C++
To use the OneAgent SDK, you need access to the source code of the application you want to monitor. The SDK enables you to instrument your application manually. The OneAgent SDK for C/C++ currently supports remote call tracing and SQL database request tracing and will be extended in the next months.
The best way to get started is to check out our GitHub repository. Here you’ll find all the necessary SDK documentation, including the hosted API documentation.
You can deploy your application as usual once you’ve compiled your application against the OneAgent SDK for C/C++. Instrumentation has no negative effect on your application. Instrumentation remains dormant on systems where Dynatrace OneAgent isn’t installed.
Automatic detection and deep monitoring of native applications
Deploy your native application on any system that’s monitored by Dynatrace. Note that you should restart your application if it was running at the time of OneAgent installation. OneAgent automatically detects that your application is instrumented with the SDK and immediately begins monitoring it on the request level, just as it does with Java and Node.js.
Note that while you do need to access the code of your native application to get the full OneAgent experience on a monitored system, you only need to restart the application once OneAgent is installed to begin monitoring.
Program samples
The following native programs are part of the samples that come with the SDK.
This is a simple sample program that takes in a remote call, calls another component, and makes a database call. Once a service starts on a monitored host, you’ll see the service listed on the Transactions & services page (see example below).
The OneAgent SDK is fully compatible with OneAgent. SDK-instrumented remote calls are shown in the form of RPC service
services, which behave just like any other service. You get full access to all analysis and monitoring functionality, including auto-baselining and AI-based root cause analysis.
Notice that this service calls another service and a database, just as expected. Let’s take a look at the Service flow and Smartscape to get a sense of what’s going on here.
As you can see, OneAgent recorded six requests to the service sample1.input_processor
. From here, we can analyze the individual requests in PurePaths view.
You can see that most of the time is spent in the process method, but the transform remote method on another service is also called.
Looking at the code level, we see the schematic structure of the recorded PurePath, along with all related timings.
Some database calls were recorded. You can see the newly detected database service that was traced via the SDK.
Extend AI-based root cause analysis
Dynatrace OneAgent SDK C/C++ provides more than just visibility into your C applications; it extends visibility across your application landscape. All discovered services and databases are monitored automatically with the same level of monitoring detail. This means that requests to the sample1
sample application are baselined along with all the SQL statements of the newly discovered database. If a service slows down, begins producing errors, or crashes, Dynatrace will detect the issue and identify the root cause.
Together with the Dynatrace OneAgent SDK for Java, the Dynatrace OneAgent SDK for C/C++ can extend your service flows to bridge calls into C processes.
What about Python, Ruby, Perl, and Erlang?
Python, Ruby, Perl, and Erlang can all make calls to C via language bindings. We don’t plan to add language bindings for all four of these languages ourselves, but we do hope to have something for Python later in 2018. Let us know if you want to build such language bindings on top of the Dynatrace SDK. We’ll be happy to host these in our GitHub repository.
Your feedback on the OneAgent SDK for C/C++ is most welcome. The best way for you to do this is via our GitHub repository issue tracker. You can also comment on our roadmap thread in AnswerHub.
Prerequisites and limitations:
- Dynatrace OneAgent SDK for C/C++
- Linux or Windows x86 architecture
- Dynatrace OneAgent v1.133 or higher
- Dynatrace Managed (version 138 or higher) or Dynatrace SaaS
Looking for answers?
Start a new discussion or ask for help in our Q&A forum.
Go to forum