This project delivers an OpenTelemetry Java Agent extension with a dynamically configurable sampler, along with the optional REST service for configuring it.
Apache License 2.0
12
stars
1
forks
source link
Have the configuration service collect sampler metrics #4
Metrics collected from all registered OTEL agents are now available from the Prometheus-compatible /metrics endpoint. For example:
❯ curl http://localhost:8080/metrics
# HELP otel_agents_recorded_samples_total the number of samples recorded by the underlying sampler
# TYPE otel_agents_recorded_samples_total counter
otel_agents_recorded_samples_total{otel_service_name="da-otel-agent-service",} 58.0
otel_agents_recorded_samples_total{otel_service_name="my-service",} 100.0
# HELP otel_agents_included_samples_total the number of samples dropped due to filtering rules
# TYPE otel_agents_included_samples_total counter
otel_agents_included_samples_total{otel_service_name="da-otel-agent-service",} 0.0
otel_agents_included_samples_total{otel_service_name="my-service",} 100.0
# HELP otel_agents_dropped_samples_total the number of samples dropped by the underlying sampler
# TYPE otel_agents_dropped_samples_total counter
otel_agents_dropped_samples_total{otel_service_name="da-otel-agent-service",} 5.0
otel_agents_dropped_samples_total{otel_service_name="my-service",} 100.0
# HELP otel_agents_total_samples_total the total number of samples processed
# TYPE otel_agents_total_samples_total counter
otel_agents_total_samples_total{otel_service_name="da-otel-agent-service",} 68.0
otel_agents_total_samples_total{otel_service_name="my-service",} 100.0
# HELP otel_agents_excluded_samples_total the number of samples recorded due to filtering rules
# TYPE otel_agents_excluded_samples_total counter
otel_agents_excluded_samples_total{otel_service_name="da-otel-agent-service",} 5.0
otel_agents_excluded_samples_total{otel_service_name="my-service",} 100.0
Each counter is tagged with the otel_service_name so that the source can be identified.
Metrics collected from all registered OTEL agents are now available from the Prometheus-compatible
/metrics
endpoint. For example:Each counter is tagged with the
otel_service_name
so that the source can be identified.