canonical / prometheus-juju-exporter

GNU General Public License v3.0
2 stars 8 forks source link

Backward compatible feature to specify more than one controller endpoint #39

Closed mkalcok closed 1 year ago

mkalcok commented 1 year ago

This change allow specification of multiple controllers in the config file. This is meant to accommodate HA juju setups with multiple controllers, not to specify multiple standalone controllers. Collector will automatically fail over to the next controller in the list in case the first controller on the list fails.

mkalcok commented 1 year ago

Thanks @agileshaw, Yeah, I agree that those tests should be improved to catch both "single string" and "list of strings" scenario

mkalcok commented 1 year ago

@agileshaw Unit tests are updated.

Test for config parsing in test_collector.py (line #22) should be updated accordingly

I did not alter this test, as it is in line with the format of the juju.controller_endpoint config option loaded from the test config.