Skip to content

Commit 68b92fa

Browse files
committed
update observation
1 parent c6a0e47 commit 68b92fa

File tree

4 files changed

+17
-5
lines changed

4 files changed

+17
-5
lines changed

examples/observation-docker/config/otel-collector.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,16 @@ exporters:
88
endpoint: tempo:4317
99
tls:
1010
insecure: true
11+
prometheus:
12+
endpoint: "otel-collector:10010"
13+
send_timestamps: true
14+
resource_to_telemetry_conversion:
15+
enabled: true
1116
service:
1217
pipelines:
18+
metrics:
19+
receivers: [ otlp ]
20+
exporters: [ prometheus ]
1321
traces:
1422
receivers: [ otlp ]
1523
exporters: [ otlp ]

examples/observation-docker/config/prometheus.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,7 @@ scrape_configs:
88
- targets: [ 'localhost:9090' ]
99
- job_name: 'tempo'
1010
static_configs:
11-
- targets: [ 'tempo:3200' ]
11+
- targets: [ 'tempo:3200' ]
12+
- job_name: 'otel-collector'
13+
static_configs:
14+
- targets: [ 'otel-collector:10010' ]

examples/observation-docker/observation.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
version: "3"
21
services:
32

43
# And put them in an OTEL collector pipeline...
@@ -25,7 +24,7 @@ services:
2524
- "9411" # zipkin
2625

2726
prometheus:
28-
image: prom/prometheus:v2.51.1
27+
image: prom/prometheus:v3.2.0
2928
command:
3029
- --config.file=/etc/prometheus.yaml
3130
- --web.enable-remote-write-receiver

examples/src/main/resources/application.yaml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,10 @@ spring:
1212
logging:
1313
level:
1414
org.springframework.ai.chat.client.advisor.SimpleLoggerAdvisor: DEBUG
15+
management:
16+
tracing:
17+
sampling:
18+
probability: 1.0
1519
otel:
16-
metrics:
17-
exporter: none
1820
logs:
1921
exporter: none

0 commit comments

Comments
 (0)