Перейти к содержимому

Prometheus Metrics

Это содержимое пока не доступно на вашем языке.

NORA exposes Prometheus-compatible metrics at the /metrics endpoint. No authentication is required.

Terminal window
curl http://localhost:4000/metrics
MetricTypeLabelsDescription
nora_http_requests_totalCounterregistry, method, statusTotal HTTP requests processed
nora_http_request_duration_secondsHistogramregistry, methodRequest latency (buckets: 1ms to 10s)

The registry label is derived from the request path:

Path prefixLabel
/v2*docker
/npm*npm
/simple*, /packages*pypi
/maven2*maven
/cargo*cargo
/go/*go
/raw/*raw
/gems/*gems
/terraform/*terraform
/ansible/*ansible
/nuget/*nuget
/pub/*pub
/conan/*conan
/ui*ui
(other paths)other
MetricTypeLabelsDescription
nora_cache_requests_totalCounterregistry, resultCache lookups (hit or miss)
MetricTypeLabelsDescription
nora_storage_operations_totalCounteroperation, statusStorage operations (get, put, delete, list) with ok or error status
nora_artifacts_totalCounterregistryTotal artifacts stored per registry

Available when NORA_CB_ENABLED=true.

MetricTypeLabelsDescription
nora_circuit_breaker_stateGaugeregistryCurrent state: 0 = closed, 1 = open, 2 = half-open
nora_circuit_breaker_rejections_totalCounterregistryRequests rejected by an open breaker
MetricTypeDescription
nora_gc_blobs_removed_totalCounterOrphaned blobs removed by GC
nora_gc_bytes_freed_totalCounterBytes freed by GC
nora_gc_duration_secondsHistogramDuration of GC runs (buckets: 0.1s to 300s)
nora_gc_last_run_timestampGaugeUnix timestamp of last GC run
nora_gc_metadata_phantoms_totalCounterPhantom version entries cleaned from metadata
MetricTypeDescription
nora_retention_versions_deleted_totalCounterVersions removed by retention policies
nora_retention_bytes_freed_totalCounterBytes freed by retention
nora_retention_duration_secondsHistogramDuration of retention runs (buckets: 0.1s to 300s)
nora_retention_last_run_timestampGaugeUnix timestamp of last retention run
# Request rate by registry (5m window)
sum by (registry) (rate(nora_http_requests_total[5m]))
# Cache hit ratio
sum(rate(nora_cache_requests_total{result="hit"}[5m]))
/
sum(rate(nora_cache_requests_total[5m]))
# p99 latency per registry
histogram_quantile(0.99, sum by (le, registry) (rate(nora_http_request_duration_seconds_bucket[5m])))
# Circuit breaker alerts (open state)
nora_circuit_breaker_state == 1
# GC bytes freed per hour
increase(nora_gc_bytes_freed_total[1h])
prometheus.yml
scrape_configs:
- job_name: nora
scrape_interval: 15s
static_configs:
- targets: ['nora:4000']
metrics_path: /metrics