Emily
04/10/2024, 8:54 PMotelCollectorMetrics:
ports:
prometheus:
enabled: true
containerPort: 9464
servicePort: 9464
protocol: TCP
config:
receivers:
prometheus:
config:
scrape_configs:
- job_name: kubernetes-services
kubernetes_sd_configs:
- role: service
exporters:
prometheus:
endpoint: 0.0.0.0:9464
service:
pipelines:
metrics:
exporters: [clickhousemetricswrite]
I also want the OpenTelemetry Collector to expose a Prometheus endpoint. But as soon as I add "prometheus" to the list of exporters, I see recursively added labels with an "exported" prefix. For example, "exported_exported_job", "exported_exported_exported_job", "exported_exported_exported_exported_job", etc. Am I configuring the prometheus exporter incorrectly?Eric Thompson
04/10/2024, 9:14 PMEric Thompson
04/10/2024, 10:31 PMapiVersion: <http://opentelemetry.io/v1alpha1|opentelemetry.io/v1alpha1>
kind: OpenTelemetryCollector
metadata:
name: prometheus-scraper
spec:
mode: deployment # This configuration is omittable.
config: |
receivers:
otlp:
protocols:
grpc: {}
http: {}
prometheus:
config:
global:
scrape_interval: 20s # Adjust this interval as needed
scrape_configs:
- job_name: 'kong'
static_configs:
- targets: ['kong-metrics:9119']
- job_name: 'mongodb'
static_configs:
- targets: ['mongodb-metrics:9216']
- job_name: 'nats'
static_configs:
- targets: ['nats-metrics:7777']
processors:
batch:
send_batch_size: 1000
timeout: 10s
attributes/upsert:
attributes:
- key: deployment.environment
value: dev
action: insert
actions:
- key: k8s_cluster_name
value: dev
action: upsert
- key: k8s_namespace_name
value: dev
action: upsert
exporters:
otlp:
endpoint: "ingest.signoz.host.name:4317"
tls:
insecure: true
timeout: 20s # Adjust the timeout value as needed
logging:
verbosity: detailed
service:
telemetry:
metrics:
address: localhost:8888
pipelines:
metrics:
receivers: [otlp, prometheus]
processors: [attributes/upsert, batch]
#processors: [batch]
exporters: [otlp]
Eric Thompson
04/10/2024, 10:31 PM