Last active
December 31, 2023 17:01
-
-
Save Tsugami/d1c29ac870b1f5748443813029481d61 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3.9' | |
networks: | |
default: | |
name: opentelemetry-demo | |
driver: bridge | |
services: | |
otel-collector: | |
image: otel/opentelemetry-collector-contrib | |
volumes: | |
- ./otel-collector-config.yaml:/etc/otelcol-contrib/config.yaml | |
ports: | |
- "4317" # OTLP over gRPC receiver | |
- "4318:4318" # OTLP over HTTP receiver | |
- "9464" # Prometheus exporter | |
- "8888" # metrics endpoint | |
jaeger: | |
image: jaegertracing/all-in-one:1.48.0 | |
container_name: jaeger | |
command: | |
- "--memory.max-traces" | |
- "10000" | |
- "--query.base-path" | |
- "/jaeger/ui" | |
- "--prometheus.server-url" | |
- "http://${PROMETHEUS_ADDR}" | |
- "--prometheus.query.support-spanmetrics-connector=true" | |
deploy: | |
resources: | |
limits: | |
memory: 300M | |
restart: unless-stopped | |
ports: | |
- 16686:16686 # Jaeger UI | |
- "4317" # OTLP gRPC default port | |
environment: | |
- COLLECTOR_OTLP_ENABLED=true | |
- METRICS_STORAGE_TYPE=prometheus | |
prometheus: | |
image: quay.io/prometheus/prometheus:v2.46.0 | |
container_name: prometheus | |
command: | |
- --web.console.templates=/etc/prometheus/consoles | |
- --web.console.libraries=/etc/prometheus/console_libraries | |
- --storage.tsdb.retention.time=1h | |
- --config.file=/etc/prometheus/prometheus-config.yaml | |
- --storage.tsdb.path=/prometheus | |
- --web.enable-lifecycle | |
- --web.route-prefix=/ | |
- --enable-feature=exemplar-storage | |
- --enable-feature=otlp-write-receiver | |
volumes: | |
- ./docker/prometheus/prometheus-config.yml:/etc/prometheus/prometheus-config.yaml | |
deploy: | |
resources: | |
limits: | |
memory: 300M | |
ports: | |
- "9090:9090" | |
grafana: | |
image: grafana/grafana:10.1.0 | |
container_name: grafana | |
deploy: | |
resources: | |
limits: | |
memory: 100M | |
volumes: | |
- ./docker/grafana/provisioning/:/etc/grafana/provisioning/ | |
ports: | |
- "${GRAFANA_SERVICE_PORT}:3000" | |
environment: | |
- GF_AUTH_ANONYMOUS_ENABLED=true | |
- GF_AUTH_ANONYMOUS_ORG_ROLE=Admin | |
- GF_AUTH_DISABLE_LOGIN_FORM=true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2023-09-29T16:19:21.105Z info service@v0.86.0/service.go:138 Starting otelcol-contrib... {"Version": "0.86.0", "NumCPU": 12} | |
2023-09-29T16:19:21.105Z info extensions/extensions.go:31 Starting extensions... | |
2023-09-29T16:19:21.106Z info service@v0.86.0/service.go:170 Starting shutdown... | |
2023-09-29T16:19:21.106Z info spanmetricsconnector@v0.86.0/connector.go:187 Shutting down spanmetrics connector {"kind": "exporter", "name": "spanmetrics", "exporter_in_pipeline": "traces", "receiver_in_pipeline": "metrics"} | |
2023-09-29T16:19:21.106Z info extensions/extensions.go:45 Stopping extensions... | |
2023-09-29T16:19:21.106Z info service@v0.86.0/service.go:184 Shutdown complete. | |
Error: cannot start pipelines: listen tcp 172.30.0.3:8889: bind: cannot assign requested address | |
2023/09/29 16:19:21 collector server run finished with error: cannot start pipelines: listen tcp 172.30.0.3:8889: bind: cannot assign requested address | |
2023-09-29T16:25:08.248Z info service@v0.86.0/telemetry.go:84 Setting up own telemetry... | |
2023-09-29T16:25:08.248Z info service@v0.86.0/telemetry.go:201 Serving Prometheus metrics {"address": ":8888", "level": "Basic"} | |
2023-09-29T16:25:08.248Z info exporter@v0.86.0/exporter.go:275 Deprecated component. Will be removed in future releases. {"kind": "exporter", "data_type": "metrics", "name": "logging"} | |
2023-09-29T16:25:08.248Z info spanmetricsconnector@v0.86.0/connector.go:98 Building spanmetrics connector {"kind": "exporter", "name": "spanmetrics", "exporter_in_pipeline": "traces", "receiver_in_pipeline": "metrics"} | |
2023-09-29T16:25:08.248Z info exporter@v0.86.0/exporter.go:275 Deprecated component. Will be removed in future releases. {"kind": "exporter", "data_type": "traces", "name": "logging"} | |
2023-09-29T16:25:08.250Z info service@v0.86.0/service.go:138 Starting otelcol-contrib... {"Version": "0.86.0", "NumCPU": 12} | |
2023-09-29T16:25:08.250Z info extensions/extensions.go:31 Starting extensions... | |
2023-09-29T16:25:08.250Z info spanmetricsconnector@v0.86.0/connector.go:167 Starting spanmetrics connector {"kind": "exporter", "name": "spanmetrics", "exporter_in_pipeline": "traces", "receiver_in_pipeline": "metrics"} | |
2023-09-29T16:25:08.251Z warn internal@v0.86.0/warning.go:40 Using the 0.0.0.0 address exposes this server to every network interface, which may facilitate Denial of Service attacks {"kind": "receiver", "name": "otlp", "data_type": "metrics", "documentation": "https://github.com/open-telemetry/opentelemetry-collector/blob/main/docs/security-best-practices.md#safeguards-against-denial-of-service-attacks"} | |
2023-09-29T16:25:08.251Z info otlpreceiver@v0.86.0/otlp.go:83 Starting GRPC server {"kind": "receiver", "name": "otlp", "data_type": "metrics", "endpoint": "0.0.0.0:4317"} | |
2023-09-29T16:25:08.251Z warn internal@v0.86.0/warning.go:40 Using the 0.0.0.0 address exposes this server to every network interface, which may facilitate Denial of Service attacks {"kind": "receiver", "name": "otlp", "data_type": "metrics", "documentation": "https://github.com/open-telemetry/opentelemetry-collector/blob/main/docs/security-best-practices.md#safeguards-against-denial-of-service-attacks"} | |
2023-09-29T16:25:08.251Z info otlpreceiver@v0.86.0/otlp.go:101 Starting HTTP server {"kind": "receiver", "name": "otlp", "data_type": "metrics", "endpoint": "0.0.0.0:4318"} | |
2023-09-29T16:25:08.251Z info service@v0.86.0/service.go:161 Everything is ready. Begin running and processing data. | |
2023-09-29T16:25:13.103Z info otelcol@v0.86.0/collector.go:250 Received signal from OS {"signal": "terminated"} | |
2023-09-29T16:25:13.103Z info service@v0.86.0/service.go:170 Starting shutdown... | |
2023-09-29T16:25:13.103Z info spanmetricsconnector@v0.86.0/connector.go:187 Shutting down spanmetrics connector {"kind": "exporter", "name": "spanmetrics", "exporter_in_pipeline": "traces", "receiver_in_pipeline": "metrics"} | |
2023-09-29T16:25:13.103Z info spanmetricsconnector@v0.86.0/connector.go:189 Stopping ticker {"kind": "exporter", "name": "spanmetrics", "exporter_in_pipeline": "traces", "receiver_in_pipeline": "metrics"} | |
2023-09-29T16:25:13.103Z info extensions/extensions.go:45 Stopping extensions... | |
2023-09-29T16:25:13.103Z info service@v0.86.0/service.go:184 Shutdown complete. | |
2023-09-29T16:25:14.501Z info service@v0.86.0/telemetry.go:84 Setting up own telemetry... | |
2023-09-29T16:25:14.501Z info service@v0.86.0/telemetry.go:201 Serving Prometheus metrics {"address": ":8888", "level": "Basic"} | |
2023-09-29T16:25:14.501Z info exporter@v0.86.0/exporter.go:275 Deprecated component. Will be removed in future releases. {"kind": "exporter", "data_type": "traces", "name": "logging"} | |
2023-09-29T16:25:14.501Z info exporter@v0.86.0/exporter.go:275 Deprecated component. Will be removed in future releases. {"kind": "exporter", "data_type": "metrics", "name": "logging"} | |
2023-09-29T16:25:14.501Z info spanmetricsconnector@v0.86.0/connector.go:98 Building spanmetrics connector {"kind": "exporter", "name": "spanmetrics", "exporter_in_pipeline": "traces", "receiver_in_pipeline": "metrics"} | |
2023-09-29T16:25:14.502Z info service@v0.86.0/service.go:138 Starting otelcol-contrib... {"Version": "0.86.0", "NumCPU": 12} | |
2023-09-29T16:25:14.502Z info extensions/extensions.go:31 Starting extensions... | |
2023-09-29T16:25:14.502Z warn internal@v0.86.0/warning.go:40 Using the 0.0.0.0 address exposes this server to every network interface, which may facilitate Denial of Service attacks {"kind": "receiver", "name": "otlp", "data_type": "traces", "documentation": "https://github.com/open-telemetry/opentelemetry-collector/blob/main/docs/security-best-practices.md#safeguards-against-denial-of-service-attacks"} | |
2023-09-29T16:25:14.502Z info otlpreceiver@v0.86.0/otlp.go:83 Starting GRPC server {"kind": "receiver", "name": "otlp", "data_type": "traces", "endpoint": "0.0.0.0:4317"} | |
2023-09-29T16:25:14.502Z warn internal@v0.86.0/warning.go:40 Using the 0.0.0.0 address exposes this server to every network interface, which may facilitate Denial of Service attacks {"kind": "receiver", "name": "otlp", "data_type": "traces", "documentation": "https://github.com/open-telemetry/opentelemetry-collector/blob/main/docs/security-best-practices.md#safeguards-against-denial-of-service-attacks"} | |
2023-09-29T16:25:14.502Z info otlpreceiver@v0.86.0/otlp.go:101 Starting HTTP server {"kind": "receiver", "name": "otlp", "data_type": "traces", "endpoint": "0.0.0.0:4318"} | |
2023-09-29T16:25:14.502Z info spanmetricsconnector@v0.86.0/connector.go:167 Starting spanmetrics connector {"kind": "exporter", "name": "spanmetrics", "exporter_in_pipeline": "traces", "receiver_in_pipeline": "metrics"} | |
2023-09-29T16:25:14.503Z info service@v0.86.0/service.go:161 Everything is ready. Begin running and processing data. | |
2023-09-29T16:26:41.092Z info TracesExporter {"kind": "exporter", "data_type": "traces", "name": "logging", "resource spans": 1, "spans": 30} | |
2023-09-29T16:26:44.688Z info MetricsExporter {"kind": "exporter", "data_type": "metrics", "name": "logging", "resource metrics": 1, "metrics": 2, "data points": 50} | |
2023-09-29T16:26:44.696Z error exporterhelper/retry_sender.go:145 Exporting failed. The error is not retryable. Dropping data. {"kind": "exporter", "data_type": "metrics", "name": "otlphttp/prometheus", "error": "Permanent error: error exporting items, request to http://prometheus:9090/api/v1/otlp/v1/metrics responded with HTTP Status Code 404", "dropped_items": 50} | |
go.opentelemetry.io/collector/exporter/exporterhelper.(*retrySender).send | |
go.opentelemetry.io/collector/exporter@v0.86.0/exporterhelper/retry_sender.go:145 | |
go.opentelemetry.io/collector/exporter/exporterhelper.(*metricsSenderWithObservability).send | |
go.opentelemetry.io/collector/exporter@v0.86.0/exporterhelper/metrics.go:176 | |
go.opentelemetry.io/collector/exporter/exporterhelper.(*queueSender).start.func1 | |
go.opentelemetry.io/collector/exporter@v0.86.0/exporterhelper/queue_sender.go:124 | |
go.opentelemetry.io/collector/exporter/exporterhelper/internal.(*boundedMemoryQueue).Start.func1 | |
go.opentelemetry.io/collector/exporter@v0.86.0/exporterhelper/internal/bounded_memory_queue.go:52 | |
2023-09-29T16:26:46.906Z info TracesExporter {"kind": "exporter", "data_type": "traces", "name": "logging", "resource spans": 1, "spans": 261} | |
2023-09-29T16:26:52.316Z info TracesExporter {"kind": "exporter", "data_type": "traces", "name": "logging", "resource spans": 1, "spans": 34} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
receivers: | |
otlp: | |
protocols: | |
grpc: | |
http: | |
processors: | |
batch: | |
exporters: | |
logging: | |
otlp: | |
endpoint: "jaeger:4317" | |
tls: | |
insecure: true | |
otlphttp/prometheus: | |
endpoint: "http://prometheus:9090/api/v1/otlp" | |
tls: | |
insecure: true | |
connectors: | |
spanmetrics: | |
service: | |
pipelines: | |
traces: | |
receivers: [otlp] | |
processors: [batch] | |
exporters: [otlp, logging, spanmetrics] | |
metrics: | |
receivers: [otlp, spanmetrics] | |
processors: [batch] | |
exporters: [otlphttp/prometheus, logging] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright The OpenTelemetry Authors | |
# SPDX-License-Identifier: Apache-2.0 | |
global: | |
evaluation_interval: 30s | |
scrape_interval: 5s | |
scrape_configs: | |
- job_name: otel | |
honor_labels: true | |
static_configs: | |
- targets: | |
- 'otel-collector:9464' | |
- job_name: otel-collector | |
static_configs: | |
- targets: | |
- 'otel-collector:8888' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment