diff --git a/docker/telemetry/grafana/provisioning/datasources/loki.yaml b/docker/telemetry/grafana/provisioning/datasources/loki.yaml index 79425630e8..f5cd051715 100644 --- a/docker/telemetry/grafana/provisioning/datasources/loki.yaml +++ b/docker/telemetry/grafana/provisioning/datasources/loki.yaml @@ -21,4 +21,4 @@ datasources: - datasourceUid: tempo matcherRegex: "trace_id=(\\w+)" name: TraceID - url: "" + url: "$${__value.raw}" diff --git a/docker/telemetry/otel-collector-config.yaml b/docker/telemetry/otel-collector-config.yaml index fc13b2442d..f8c3fe49c1 100644 --- a/docker/telemetry/otel-collector-config.yaml +++ b/docker/telemetry/otel-collector-config.yaml @@ -39,15 +39,20 @@ receivers: include: [/var/log/rippled/*/debug.log] operators: - type: regex_parser - regex: '^(?P\S+)\s+(?P\S+):(?P\S+)\s+(?:trace_id=(?P[a-f0-9]+)\s+span_id=(?P[a-f0-9]+)\s+)?(?P.*)$' + regex: '^(?P\S+\s+\S+)\s+\S+\s+(?P\S+):(?P\S+)\s+(?:trace_id=(?P[a-f0-9]+)\s+span_id=(?P[a-f0-9]+)\s+)?(?P.*)$' timestamp: parse_from: attributes.timestamp - layout: "%Y-%b-%d %H:%M:%S.%f" + layout: "%Y-%b-%d %H:%M:%S" processors: batch: timeout: 1s send_batch_size: 100 + resource/logs: + attributes: + - key: service.name + value: xrpld + action: upsert connectors: spanmetrics: @@ -96,5 +101,5 @@ service: # batches entries, and exports to Loki for log-trace correlation. logs: receivers: [filelog] - processors: [batch] + processors: [resource/logs, batch] exporters: [otlphttp/loki]