Improvements:
- better readability
- get_prom_client_from_keystone can be used by watcher for
PrometheusAPIClient initialization.
- A better split between how the client is created for Aetos and
how it's created for Prometheus.
Changes to the previous behavior of get_prometheus_client:
- It's not possible to override PrometheusAPIClient arguments with
environment variables if they're retrieved from Keystone.
- It's not possible to use config file / environment variables to
connect to Aetos (the keystone session parameter won't be passed to
PrometheusAPIClient and so it won't be able to authenticate)
I think even though, there are some changes to how Aetos can access
can be configured, it's getting it a bit closer to how other services
work (getting the endpoint from keystone and not requiring / allowing
additional configuration). Prometheus access configuration through
config file / env variables stays unchanged.
Change-Id: Icd08347056e92502992d4fee799bb3e06e03c0c9
Signed-off-by: Jaromir Wysoglad <jwysogla@redhat.com>