Mongo DB exporter panics if initial connection fails
General
Escalation
General
Escalation
Description
How to test
Run exporter with unavailable mongodb (i.e. some fake server 1.2.3.4)
Navigate to '/metrics' endpoint
Exporter should serve go_runtime metrics
How to document
None
Smart Checklist
Activity
Show:

Taras Shcherban October 7, 2022 at 7:16 AM
Now exporter doesn't crash if mongodb is not available, serves default metrics.
Done
Created September 12, 2022 at 10:53 AM
Updated November 13, 2024 at 9:44 AM
Resolved October 7, 2022 at 7:18 AM
User impact:
Exporter panics when handling requests if client connection fails.
Steps to reproduce:
Attempt to test/run exporter when mongodb is not available.
Actual result:
Expected result:
Exporter runs, providing only metrics from the default gatherer.