mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Tracing: Allow otel service name and attributes to be overridden from env (#85937)
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
This commit is contained in:
parent
0d42e025f0
commit
78f460c4de
@ -1925,7 +1925,7 @@ Configure general parameters shared between OpenTelemetry providers.
|
||||
|
||||
Comma-separated list of attributes to include in all new spans, such as `key1:value1,key2:value2`.
|
||||
|
||||
Can be set with the environment variable `OTEL_RESOURCE_ATTRIBUTES` (use `=` instead of `:` with the environment variable).
|
||||
Can be set or overridden with the environment variable `OTEL_RESOURCE_ATTRIBUTES` (use `=` instead of `:` with the environment variable). The service name can be set or overridden using attributes or with the environment variable `OTEL_SERVICE_NAME`.
|
||||
|
||||
### sampler_type
|
||||
|
||||
|
@ -209,6 +209,7 @@ func initTracerProvider(exp tracesdk.SpanExporter, serviceName string, serviceVe
|
||||
semconv.ServiceVersionKey.String(serviceVersion),
|
||||
),
|
||||
resource.WithAttributes(customAttribs...),
|
||||
resource.WithFromEnv(),
|
||||
resource.WithProcessRuntimeDescription(),
|
||||
resource.WithTelemetrySDK(),
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user