categraf/conf/traces.yaml

115 lines
5.4 KiB
YAML

# This is an example:
# receive spans from jaeger, send to jaeger and zipkin, with three extensions enabled.
# See factories we already supported:
# ./config/traces/components.go
# For more details, see the OpenTelemetry official docs:
# https://opentelemetry.io/docs/collector/configuration/
traces:
# set enable to true to start tracing
enable: false
# Extensions:
# provide capabilities that can be added to the Collector, but which do not require direct access to telemetry data
# and are not part of pipelines. They are also enabled within the service section.
#
# Categraf supports:
# pprof: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/extension/pprofextension
# health_check: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/extension/healthcheckextension
# basicauth: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/extension/basicauthextension
# jaegerremotesampling: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/extension/jaegerremotesampling
extensions:
pprof:
endpoint: 0.0.0.0:1777
health_check:
#jaegerremotesampling:
# source:
# remote:
# endpoint: jaeger-collector:14250
#basicauth/server:
# htpasswd:
# file: .htpasswd
# inline: |
# ${BASIC_AUTH_USERNAME}:${BASIC_AUTH_PASSWORD}
#
#basicauth/client:
# client_auth:
# username: username
# password: password
# Receiver:
# which can be push or pull based, is how data gets into the Collector. Configuring a receiver does not enable it.
# Receivers are enabled via pipelines within the service section.
#
# Categraf supports:
# jaeger: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/receiver/jaegerreceiver
# zipkin: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/receiver/zipkinreceiver
# otlp: https://github.com/open-telemetry/opentelemetry-collector/tree/main/receiver/otlpreceiver
# kafka: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/receiver/kafkareceiver
receivers:
jaeger:
protocols:
thrift_http:
endpoint: 0.0.0.0:14268
# Processor:
# run on data between being received and being exported. Configuring a processor does not enable it.
# Processors are enabled via pipelines within the service section.
#
# Categraf supports:
# batch: https://github.com/open-telemetry/opentelemetry-collector/tree/main/processor/batchprocessor
# attributes: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/processor/attributesprocessor
# resource: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/processor/resourceprocessor
# span: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/processor/spanprocessor
# tailsampling: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/processor/tailsamplingprocessor
processors:
batch/example:
send_batch_size: 1000
timeout: 10s
attributes/example:
actions:
- key: ident
value: categraf-01.bj
action: upsert
# Exporter:
# which can be push or pull based, is how you send data to one or more backends/destinations. Configuring an
# exporter does not enable it. Exporters are enabled via pipelines within the service section.
#
# Categraf supports:
# otlp: https://github.com/open-telemetry/opentelemetry-collector/tree/main/exporter/otlpexporter
# otlphttp: https://github.com/open-telemetry/opentelemetry-collector/tree/main/exporter/otlphttpexporter
# jaeger: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/exporter/jaegerexporter
# zipkin: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/exporter/zipkinexporter
# kafka: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/exporter/kafkaexporter
# alibabacloudlogservice: https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/exporter/alibabacloudlogserviceexporter
exporters:
jaeger:
endpoint: "127.0.0.1:14250"
tls:
insecure: true
zipkin:
endpoint: "http://127.0.0.1:9411/api/v2/spans"
# Service:
# used to configure what components are enabled in the Collector based on the configuration found in the receivers,
# processors, exporters, and extensions sections. If a component is configured, but not defined within the service
# section then it is not enabled. The service section consists of three sub-sections:
# - extensions: Extensions consist of a list of all extensions to enable.
# - pipelines: A pipeline consists of a set of receivers, processors and exporters.
# - telemetry: Telemetry is where the telemetry for the collector itself can be configured.
service:
extensions: [health_check, pprof]
pipelines:
traces:
receivers: [jaeger]
processors: [batch/example, attributes/example]
exporters: [jaeger, zipkin]
telemetry:
logs:
level: info
initial_fields:
service: my-instance