Get started with Trace Analytics

    1. Trace Analytics relies on you adding instrumentation to your application and generating trace data. The OpenTelemetry documentation contains example applications for many programming languages that can help you get started, including Java, Python, Go, and JavaScript.

      (In the example below, an extra component, the Jaeger agent, runs alongside the application and sends the data to the OpenTelemetry Collector, but the concept is similar.)

    2. Data Prepper processes the OpenTelemetry data, transforms it for use in OpenSearch, and indexes it on an OpenSearch cluster.

    Jaeger HotROD

    One Trace Analytics sample application is the Jaeger HotROD demo, which mimics the flow of data through a distributed application.

    Download or clone the Data Prepper repository. Then navigate to and open docker-compose.yml in a text editor. This file contains a container for each element from :

    • A distributed application (jaeger-hot-rod) with the Jaeger agent (jaeger-agent)
    • Data Prepper (data-prepper)
    • A single-node OpenSearch cluster (opensearch)
    • OpenSearch Dashboards (opensearch-dashboards).

    Close the file and run . After the containers start, navigate to http://localhost:8080 in a web browser.

    HotROD web interface

    Click one of the buttons in the web interface to send a request to the application. Each request starts a series of operations across the services that make up the application. From the console logs, you can see that these operations share the same trace-id, which lets you track all of the operations in the request as a single trace:

    Then Data Prepper processes the data from the OpenTelemetry Collector and indexes it:

    Finally, you can see the OpenSearch node responding to the indexing request.

    In a new terminal window, run the following command to see one of the raw documents in the OpenSearch cluster:

    Navigate to in a web browser and choose Trace Analytics. You can see the results of your single click in the Jaeger HotROD web interface: the number of traces per API and HTTP method, latency trends, a color-coded map of the service architecture, and a list of trace IDs that you can use to drill down on individual operations.

    If you don’t see your trace, adjust the timeframe in OpenSearch Dashboards. For more information on using the plugin, see OpenSearch Dashboards plugin.