Use the correct registry object to unregister some collectors.

pull/3405/head
derekpierre 2024-01-18 15:27:03 -05:00 committed by KPrasch
parent 5171c012ca
commit e9ea0ddb23
1 changed files with 3 additions and 3 deletions

View File

@ -125,9 +125,9 @@ def start_prometheus_exporter(
"""Configure, collect, and serve prometheus metrics."""
# Disabling default collector metrics
REGISTRY.unregister(GC_COLLECTOR)
REGISTRY.unregister(PLATFORM_COLLECTOR)
REGISTRY.unregister(PROCESS_COLLECTOR)
registry.unregister(GC_COLLECTOR)
registry.unregister(PLATFORM_COLLECTOR)
registry.unregister(PROCESS_COLLECTOR)
metrics_collectors = create_metrics_collectors(ursula)
# initialize collectors