Skip to content

Commit

Permalink
Enable exemplar export/display support
Browse files Browse the repository at this point in the history
Ensure the collector's prometheus endpoint produces exemplars
Ensure that prometheus collects and stores exemplar data
Ensure that grafana will display links to exemplars from dashboards/the explore tab
  • Loading branch information
jlawrienyt committed Jan 23, 2023
1 parent dade436 commit 8517c89
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 5 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -202,3 +202,5 @@ significant modifications will be credited to OpenTelemetry Authors.
([#700](https://github.com/open-telemetry/opentelemetry-demo/pull/700))
* Reduce spans generated from quote service
([#702](https://github.com/open-telemetry/opentelemetry-demo/pull/702))
* Enable exemplar support in the metrics exporter, Prometheus, and Grafana
([#704](https://github.com/open-telemetry/opentelemetry-demo/pull/704))
3 changes: 2 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -625,7 +625,7 @@ services:

# OpenTelemetry Collector
otelcol:
image: otel/opentelemetry-collector-contrib:0.61.0
image: otel/opentelemetry-collector-contrib:0.69.0
container_name: otel-col
deploy:
resources:
Expand Down Expand Up @@ -657,6 +657,7 @@ services:
- --storage.tsdb.path=/prometheus
- --web.enable-lifecycle
- --web.route-prefix=/
- --enable-feature=exemplar-storage
volumes:
- ./src/prometheus/prometheus-config.yaml:/etc/prometheus/prometheus-config.yaml
ports:
Expand Down
6 changes: 3 additions & 3 deletions docs/demo_features.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@ be added as the relevant SDKs are released.
Collector](https://opentelemetry.io/docs/collector/getting-started)**: all
services are instrumented and sending the generated traces and metrics to the
OpenTelemetry Collector via gRPC. The received traces are then exported to the
logs and to Jaeger.
logs and to Jaeger; received metrics and exemplars are exported to logs and Prometheus.
- **[Jaeger](https://www.jaegertracing.io)**: all generated traces are being
sent to Jaeger.
- **Synthetic Load Generation**: the application demo comes with a background
job that creates realistic usage patterns on the website using
[Locust](https://locust.io/) load generator.
- **[Prometheus](https://prometheus.io/)**: all generated metrics are scraped by
Prometheus.
- **[Prometheus](https://prometheus.io/)**: all generated metrics and exemplars
are scraped by Prometheus.
- **[Grafana](https://grafana.com/)**: all metric dashboards are stored in
Grafana.
- **[Envoy](https://www.envoyproxy.io/)**: Envoy is used as a reverse proxy for
Expand Down
2 changes: 1 addition & 1 deletion docs/metric_service_features.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Emoji Legend
| Service | Language | Instrumentation Libraries | Manual Metric Creation | Multiple Manual Metric Instruments | Metric Attributes | Resource Attributes | Exemplars | Views |
|--------------------|-----------------|---------------------------|------------------------|------------------------------------|-------------------|---------------------|----------------|----------------|
| Accounting Service | Go | :construction: | :construction: | :construction: | :construction: | :construction: | :construction: | :construction: |
| Ad | Java | :100: | :100: | :construction: | :100: | :100: | :construction: | :construction: |
| Ad | Java | :100: | :100: | :construction: | :100: | :100: | :100: | :construction: |
| Cart | .NET | :100: | :construction: | :construction: | :construction: | :construction: | :construction: | :construction: |
| Checkout | Go | :100: | :construction: | :construction: | :construction: | :construction: | :construction: | :construction: |
| Currency | C++ | :no_bell: | :construction: | :construction: | :construction: | :construction: | :construction: | :construction: |
Expand Down
8 changes: 8 additions & 0 deletions src/grafana/provisioning/datasources/default.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,11 @@ datasources:
url: http://prometheus:9090
editable: true
isDefault: true
jsonData:
exemplarTraceIdDestinations:
- datasourceUid: webstore-traces
name: trace_id

- url: http://localhost:8080/jaeger/ui/trace/$${__value.raw}
name: trace_id
urlDisplayLabel: View in Jaeger UI
1 change: 1 addition & 0 deletions src/otelcollector/otelcol-config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ exporters:
endpoint: "otelcol:9464"
resource_to_telemetry_conversion:
enabled: true
enable_open_metrics: true
processors:
batch:
spanmetrics:
Expand Down

0 comments on commit 8517c89

Please sign in to comment.