Skip to content

Commit 7f5fdef

Browse files
authored
Update tracing blog post (#453)
* Update tracing blog post
1 parent 6c44ced commit 7f5fdef

1 file changed

Lines changed: 32 additions & 2 deletions

File tree

_posts/blog/2022-06-22-2.1.0-metrics-and-tracing.md

Lines changed: 32 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,9 @@ general.micrometer.factory=org.apache.accumulo.test.metrics.TestStatsDRegistryFa
8585

8686
10. Log into Grafana (http://localhost:3003/) using the default credentials (root/root). Click the `Home` icon at the top, then click the `Accumulo Micrometer Test Dashboard`. If everything is working correctly, then you should see something like the image below.
8787

88-
![Grafana Screenshot](/images/blog/202206_metrics_and_tracing/Grafana_Screenshot.png)
88+
<a class="p-3 border rounded d-block" href="{{ site.baseurl }}/images/blog/202206_metrics_and_tracing/Grafana_Screenshot.png">
89+
<img src="{{ site.baseurl }}/images/blog/202206_metrics_and_tracing/Grafana_Screenshot.png" class="img-fluid rounded" alt="Grafana Screenshot"/>
90+
</a>
8991

9092
# Tracing
9193

@@ -118,6 +120,8 @@ general.opentelemetry.enabled=true
118120
general.opentelemetry.enabled=true
119121
```
120122

123+
**Note:** If you are using Accumulo 2.1.4 or newer, skip steps 5-6 below and follow the updated instructions in the [Updated Configuration with Newer Versions of OpenTelemetry](#updated-configuration-with-newer-versions-of-opentelemetry) section.
124+
121125
5. Configure the OpenTelemetry JavaAgent in accumulo-env.sh by uncommenting the following and updating the path to the java agent jar:
122126
```
123127
## Optionally setup OpenTelemetry SDK AutoConfigure
@@ -148,4 +152,30 @@ docker run -d --rm --name jaeger \
148152

149153
8. View traces in Jaeger UI at http://localhost:16686. You can select the service name on the left panel and click `Find Traces` to view the trace information. If everything is working correctly, then you should see something like the image below.
150154

151-
![Jaeger Screenshot](/images/blog/202206_metrics_and_tracing/Jaeger_Screenshot.png)
155+
<a class="p-3 border rounded d-block" href="{{ site.baseurl }}/images/blog/202206_metrics_and_tracing/Jaeger_Screenshot.png">
156+
<img src="{{ site.baseurl }}/images/blog/202206_metrics_and_tracing/Jaeger_Screenshot.png" class="img-fluid rounded" alt="Jaeger Screenshot"/>
157+
</a>
158+
159+
## Updated Configuration with Newer Versions of OpenTelemetry
160+
161+
The original tracing example above was written for Accumulo 2.1.0 which uses OpenTelemetry 1.19.0. Accumulo 2.1.4 has been updated to use OpenTelemetry 1.48.0, which requires different configuration. When working with Accumulo 2.1.4 or any deployment using OpenTelemetry 1.48.0 or newer, use OTLP (OpenTelemetry Protocol) instead of the direct Jaeger exporter.
162+
163+
Follow steps 1–4 from the [Tracing Example](#tracing-example) section, then use these updated steps in place of steps 5-6:
164+
165+
1. Configure the OpenTelemetry JavaAgent in accumulo-env.sh with OTLP export:
166+
```bash
167+
JAVA_OPTS=('-Dotel.traces.exporter=otlp' '-Dotel.exporter.otlp.endpoint=http://localhost:4317' '-Dotel.metrics.exporter=none' '-Dotel.logs.exporter=none' "${JAVA_OPTS[@]}")
168+
JAVA_OPTS=('-javaagent:path/to/opentelemetry-javaagent.jar' "${JAVA_OPTS[@]}")
169+
```
170+
2. Start Jaeger with OTLP support:
171+
```bash
172+
docker run --rm --name jaeger \
173+
-p 16686:16686 \
174+
-p 4317:4317 \
175+
-p 4318:4318 \
176+
-p 5778:5778 \
177+
-p 9411:9411 \
178+
jaegertracing/jaeger:2.3.0
179+
```
180+
181+
After completing these updated steps, continue with steps 7-8 from the original instructions to view traces in Jaeger.

0 commit comments

Comments
 (0)