Skip to content

Instantly share code, notes, and snippets.

@up1
Last active November 29, 2025 10:57
Show Gist options
  • Select an option

  • Save up1/11d396b0fd0ebb85c86e7fdde2646a4b to your computer and use it in GitHub Desktop.

Select an option

Save up1/11d396b0fd0ebb85c86e7fdde2646a4b to your computer and use it in GitHub Desktop.
OpenTelemetry in Spring Boot 4
spring.application.name=otel
# For demo only
management.tracing.sampling.probability=1.0
management.otlp.metrics.export.step=10s
management.observations.annotations.enabled=true
management.opentelemetry.tracing.export.otlp.transport=http
management.otlp.metrics.export.url=http://localhost:4318/v1/metrics
management.opentelemetry.tracing.export.otlp.endpoint=http://localhost:4318/v1/traces
management.opentelemetry.logging.export.otlp.endpoint=http://localhost:4318/v1/logs
services:
grafana-lgtm:
image: 'grafana/otel-lgtm:latest'
ports:
- '3000:3000'
- '4317:4317'
- '4318:4318'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment