Support setting Nova API microversion for openstack-exporter
Starting from v1.5.0 of the exporter, OS_COMPUTE_API_VERSION can be set to configure the Nova API version to be used [1]. Microversion 2.1 can be used to keep metrics unmodified from the previous exporter version deployed by Kolla (v1.3.0). Support it with prometheus_openstack_exporter_compute_api_version, defaulting to using the latest version. [1] https://github.com/openstack-exporter/openstack-exporter/pull/201 Change-Id: I7605a3f9f74effb29ecec3b28e4709fd5f7f8cd4
This commit is contained in:
parent
889c0d168c
commit
41fba3c5df
@ -1118,6 +1118,7 @@ prometheus_elasticsearch_exporter_interval: "{{ prometheus_scrape_interval }}"
|
||||
prometheus_cmdline_extras:
|
||||
prometheus_ceph_mgr_exporter_endpoints: []
|
||||
prometheus_openstack_exporter_endpoint_type: "internal"
|
||||
prometheus_openstack_exporter_compute_api_version: "latest"
|
||||
prometheus_libvirt_exporter_interval: "60s"
|
||||
|
||||
############
|
||||
|
@ -76,6 +76,8 @@ prometheus_services:
|
||||
container_name: "prometheus_openstack_exporter"
|
||||
group: "prometheus-openstack-exporter"
|
||||
enabled: "{{ enable_prometheus_openstack_exporter | bool }}"
|
||||
environment:
|
||||
OS_COMPUTE_API_VERSION: "{{ prometheus_openstack_exporter_compute_api_version }}"
|
||||
image: "{{ prometheus_openstack_exporter_image_full }}"
|
||||
volumes: "{{ prometheus_openstack_exporter_default_volumes + prometheus_openstack_exporter_extra_volumes }}"
|
||||
dimensions: "{{ prometheus_openstack_exporter_dimensions }}"
|
||||
|
@ -117,6 +117,7 @@
|
||||
image: "{{ service.image }}"
|
||||
volumes: "{{ service.volumes }}"
|
||||
dimensions: "{{ service.dimensions }}"
|
||||
environment: "{{ service.environment|default(omit) }}"
|
||||
when:
|
||||
- kolla_action != "config"
|
||||
|
||||
|
@ -9,6 +9,7 @@
|
||||
pid_mode: "{{ item.value.pid_mode|default('') }}"
|
||||
volumes: "{{ item.value.volumes }}"
|
||||
dimensions: "{{ item.value.dimensions }}"
|
||||
environment: "{{ item.value.environment|default(omit) }}"
|
||||
when:
|
||||
- inventory_hostname in groups[item.value.group]
|
||||
- item.value.enabled | bool
|
||||
|
@ -0,0 +1,7 @@
|
||||
---
|
||||
features:
|
||||
- |
|
||||
Adds support for configuring the Openstack Compute API microversion used by
|
||||
the OpenStack exporter for Prometheus using the
|
||||
``prometheus_openstack_exporter_compute_api_version`` variable. The default
|
||||
value is ``latest``, matching the default behaviour of the exporter.
|
Loading…
Reference in New Issue
Block a user