1
0
mirror of https://github.com/openshift/openshift-docs.git synced 2026-02-05 12:46:18 +01:00
Files
openshift-docs/modules/ossm-tutorial-jaeger-generating-traces.adoc
2024-06-24 15:07:44 +00:00

53 lines
2.2 KiB
Plaintext

////
This module is included in the following assemblies:
* service_mesh/v1x/ossm-observability.adoc
* service_mesh/v2x/ossm-observability.adoc
////
:_mod-docs-content-type: PROCEDURE
[id="generating-sample-traces-analyzing-trace-data_{context}"]
= Generating example traces and analyzing trace data
Jaeger is an open source distributed tracing system. With Jaeger, you can perform a trace that follows the path of a request through various microservices which make up an application. Jaeger is installed by default as part of the {SMProductShortName}.
This tutorial uses {SMProductShortName} and the Bookinfo sample application to demonstrate how you can use Jaeger to perform distributed tracing.
.Prerequisites
* {product-title} 4.1 or higher installed.
* {SMProductName} {SMProductVersion} installed.
* Jaeger enabled during the installation.
* Bookinfo example application installed.
.Procedure
. After installing the Bookinfo sample application, send traffic to the mesh. Enter the following command several times.
+
[source,terminal]
----
$ curl "http://$GATEWAY_URL/productpage"
----
+
This command simulates a user visiting the `productpage` microservice of the application.
. In the {product-title} console, navigate to *Networking* -> *Routes* and search for the Jaeger route, which is the URL listed under *Location*.
* Alternatively, use the CLI to query for details of the route. In this example, `istio-system` is the {SMProductShortName} control plane namespace:
+
[source,terminal]
----
$ export JAEGER_URL=$(oc get route -n istio-system jaeger -o jsonpath='{.spec.host}')
----
+
.. Enter the following command to reveal the URL for the Jaeger console. Paste the result in a browser and navigate to that URL.
+
[source,terminal]
----
echo $JAEGER_URL
----
. Log in using the same user name and password as you use to access the {product-title} console.
. In the left pane of the Jaeger dashboard, from the *Service* menu, select *productpage.bookinfo* and click *Find Traces* at the bottom of the pane. A list of traces is displayed.
. Click one of the traces in the list to open a detailed view of that trace. If you click the first one in the list, which is the most recent trace, you see the details that correspond to the latest refresh of the `/productpage`.