forked from mtusi2026/mtusi2026lab6
Перенесён минимум lab5 без изменения API и добавлена наблюдаемость: - OTel SDK в API и worker: traces, metrics, logs по OTLP; W3C trace context API -> outbox -> RabbitMQ -> worker (producer/consumer spans, retry в той же трассе); - OTel Collector (memory_limiter, scrub, batch, ограниченные очереди, профиль tail sampling), Prometheus, Loki, Tempo, Grafana с provisioning, dashboard и 6 alert rules с runbooks; - проверки: наблюдаемость и приватность, инциденты A/B/C, насыщение worker, переполнение очереди exporter, эксперимент трека 1 (4 конфигурации x 3 прогона); - CI job со сборкой и запуском стенда; REPORT.md с доказательствами в evidence/.
32 lines
969 B
YAML
32 lines
969 B
YAML
# Prometheus v3.2.1: metrics store. Application metrics arrive by OTLP push from the Collector
|
|
# (--web.enable-otlp-receiver, /api/v1/otlp); infrastructure self-metrics are scraped.
|
|
global:
|
|
scrape_interval: 15s
|
|
evaluation_interval: 15s
|
|
|
|
otlp:
|
|
# job=service.name, instance=service.instance.id are set by Prometheus; these become extra labels.
|
|
promote_resource_attributes:
|
|
- service.name
|
|
- service.instance.id
|
|
- service.version
|
|
- deployment.environment.name
|
|
|
|
storage:
|
|
tsdb:
|
|
# OTLP pushes from several SDKs/batches may arrive slightly out of order.
|
|
out_of_order_time_window: 10m
|
|
|
|
rule_files:
|
|
- /etc/prometheus/rules/*.yml
|
|
|
|
scrape_configs:
|
|
- job_name: otel-collector
|
|
static_configs: [{targets: ["otel-collector:8888"]}]
|
|
- job_name: tempo
|
|
static_configs: [{targets: ["tempo:3200"]}]
|
|
- job_name: loki
|
|
static_configs: [{targets: ["loki:3100"]}]
|
|
- job_name: prometheus
|
|
static_configs: [{targets: ["localhost:9090"]}]
|