Skip to content

Commit a3cd58c

Browse files
Merge new cinder metrics into master (#17422)
* [PLINT-357] Adding /v3/{project_id}/volumes metrics (#17380) * adding cinder metric openstack.cinder.volume.count (/v3/{project_id}/volumes/detail) * Adding a changelog * fixed linting * more linting * fixed changelog number * generalizing process_files logic * linting * relying on .slash file again * added pagination support for rest api * linting * more linting * added pagination support for sdk api * removing unnecessary comment * Update openstack_controller/changelog.d/17379.added Co-authored-by: Sarah Witt <sarah.witt@datadoghq.com> * Addressing comments. --------- Co-authored-by: Sarah Witt <sarah.witt@datadoghq.com> * [PLINT-358] Adding cinder volume transfer metrics (#17391) * adding cinder metric openstack.cinder.volume.count (/v3/{project_id}/volumes/detail) * Adding a changelog * fixed linting * more linting * fixed changelog number * generalizing process_files logic * linting * relying on .slash file again * added pagination support for rest api * linting * more linting * added pagination support for sdk api * adding cinder metric openstack.cinder.volume.transfer.count (/v3/{project_id}/os-volume-transfer/detail) * addressed comments. * [PLINT-357] Changing volume size from a tag to a metric openstack.cinder.volume.size (#17401) * Changing volume size from a tag to a metric openstack.cinder.volume.size * added a changelog Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * adding a non-empty volume name Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * fixing changelog Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> --------- Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * [PLINT-364] Add cinder pool metrics (#17412) * adding new metric openstack.cinder.pool.count Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * converting total_capacity_gb and free_capacity_gb into metrics * lint * fixed ordering of metadata.csv Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * added reserved_percentage as a metric Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * added volume_backend_name as a separate tag from name Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> --------- Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * [PLINT-360] Add cinder snapshot metrics (#17393) * adding cinder metric openstack.cinder.volume.count (/v3/{project_id}/volumes/detail) * Adding a changelog * fixed linting * more linting * fixed changelog number * generalizing process_files logic * linting * relying on .slash file again * added pagination support for rest api * linting * more linting * added pagination support for sdk api * adding cinder metric openstack.cinder.volume.transfer.count (/v3/{project_id}/os-volume-transfer/detail) * adding cinder metric openstack.cinder.snapshot.count (/v3/{project_id}/snapshots/detail) Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * changed snapshot size from tag to metric openstack.cinder.snapshot.size Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * lint Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * updating instance.py Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> --------- Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * [PLINT-365] Add cinder cluster metrics (#17416) * adding metric openstack.cinder.cluster.count Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * resolved overlapping test names Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * adding openstack.cinder.cluster.num_hosts and openstack.cinder.cluster.num_down_hosts Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * reordered metadata.csv Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * lint Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * lint Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * fixed _validate_microversion logic Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * removed debugging print statements Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> --------- Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * fixed changelog Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * fixed changelog Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * fixed changelog Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * adding extra testing coverage Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> * lint Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> --------- Signed-off-by: rahulkaukuntla <rahul.kaukuntla@datadoghq.com> Co-authored-by: Sarah Witt <sarah.witt@datadoghq.com>
1 parent 48d2443 commit a3cd58c

File tree

35 files changed

+1592
-3
lines changed

35 files changed

+1592
-3
lines changed

openstack_controller/assets/configuration/spec.yaml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,18 @@ files:
182182
example: "2.93"
183183
type: string
184184
display_default: null
185+
- name: cinder_microversion
186+
description: |
187+
The microversion of the Rest API to call.
188+
It is recommended to set this parameter to the latest microversion supported by your Openstack version.
189+
190+
View this page for more about microvoersion compatibility:
191+
https://docs.openstack.org/cinder/latest/contributor/api_microversion_history.html
192+
enabled: true
193+
value:
194+
example: "volume 3.70"
195+
type: string
196+
display_default: null
185197
- name: collect_hypervisor_load
186198
hidden: true
187199
description: |
@@ -394,6 +406,17 @@ files:
394406
anyOf:
395407
- type: boolean
396408
- type: object
409+
properties:
410+
- name: volumes
411+
type: boolean
412+
- name: transfers
413+
type: boolean
414+
- name: snapshots
415+
type: boolean
416+
- name: pools
417+
type: boolean
418+
- name: clusters
419+
type: boolean
397420
- name: baremetal
398421
anyOf:
399422
- type: boolean
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Added new cinder metrics

openstack_controller/datadog_checks/openstack_controller/api/api_rest.py

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,10 @@ def _add_microversion_headers(self):
131131
self.log.debug("adding X-OpenStack-Ironic-API-Version header to `%s`", self.config.ironic_microversion)
132132
self.http.options['headers']['X-OpenStack-Ironic-API-Version'] = self.config.ironic_microversion
133133

134+
if self.config.cinder_microversion:
135+
self.log.debug("adding OpenStack-API-Version header to `%s`", self.config.cinder_microversion)
136+
self.http.options['headers']['OpenStack-API-Version'] = self.config.cinder_microversion
137+
134138
def get_identity_regions(self):
135139
response = self.http.get(
136140
'{}/v3/regions'.format(self._catalog.get_endpoint_by_type(Component.Types.IDENTITY.value))
@@ -194,6 +198,51 @@ def get_identity_limits(self):
194198
response.raise_for_status()
195199
return response.json().get('limits', [])
196200

201+
def get_block_storage_volumes(self, project_id):
202+
params = {}
203+
return self.make_paginated_request(
204+
'{}/volumes/detail'.format(self._catalog.get_endpoint_by_type(Component.Types.BLOCK_STORAGE.value)),
205+
'volumes',
206+
'id',
207+
next_signifier='volumes_links',
208+
params=params,
209+
)
210+
211+
def get_block_storage_transfers(self, project_id):
212+
response = self.http.get(
213+
'{}/os-volume-transfer/detail'.format(
214+
self._catalog.get_endpoint_by_type(Component.Types.BLOCK_STORAGE.value)
215+
)
216+
)
217+
response.raise_for_status()
218+
return response.json().get('transfers', {})
219+
220+
def get_block_storage_snapshots(self, project_id):
221+
params = {}
222+
return self.make_paginated_request(
223+
'{}/snapshots/detail'.format(self._catalog.get_endpoint_by_type(Component.Types.BLOCK_STORAGE.value)),
224+
'snapshots',
225+
'id',
226+
next_signifier='snapshots_links',
227+
params=params,
228+
)
229+
230+
def get_block_storage_pools(self, project_id):
231+
response = self.http.get(
232+
'{}/scheduler-stats/get_pools'.format(
233+
self._catalog.get_endpoint_by_type(Component.Types.BLOCK_STORAGE.value)
234+
)
235+
)
236+
response.raise_for_status()
237+
return response.json().get('pools', {})
238+
239+
def get_block_storage_clusters(self, project_id):
240+
response = self.http.get(
241+
'{}/clusters/detail'.format(self._catalog.get_endpoint_by_type(Component.Types.BLOCK_STORAGE.value))
242+
)
243+
response.raise_for_status()
244+
return response.json().get('clusters', {})
245+
197246
def get_compute_limits(self, project_id):
198247
params = {'tenant_id': project_id}
199248
response = self.http.get(

openstack_controller/datadog_checks/openstack_controller/api/api_sdk.py

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,10 @@ def _add_microversion_headers(self):
5151
self.log.debug("adding X-OpenStack-Ironic-API-Version header to `%s`", self.config.ironic_microversion)
5252
self.http.options['headers']['X-OpenStack-Ironic-API-Version'] = self.config.ironic_microversion
5353

54+
if self.config.cinder_microversion:
55+
self.log.debug("adding OpenStack-API-Version header to `%s`", self.config.cinder_microversion)
56+
self.http.options['headers']['OpenStack-API-Version'] = self.config.cinder_microversion
57+
5458
def auth_url(self):
5559
return self.cloud_config.get_auth_args().get('auth_url')
5660

@@ -154,6 +158,39 @@ def get_identity_registered_limits(self):
154158
def get_identity_limits(self):
155159
return [limit.to_dict(original_names=True) for limit in self.connection.identity.limits()]
156160

161+
def get_block_storage_volumes(self, project_id):
162+
return [
163+
volume.to_dict(original_names=True)
164+
for volume in self.call_paginated_api(
165+
self.connection.block_storage.volumes, project_id=project_id, limit=self.config.paginated_limit
166+
)
167+
]
168+
169+
def get_block_storage_transfers(self, project_id):
170+
return [
171+
transfer.to_dict(original_names=True)
172+
for transfer in self.connection.block_storage.transfers(project_id, details=True)
173+
]
174+
175+
def get_block_storage_snapshots(self, project_id):
176+
return [
177+
snapshot.to_dict(original_names=True)
178+
for snapshot in self.call_paginated_api(
179+
self.connection.block_storage.snapshots, project_id=project_id, limit=self.config.paginated_limit
180+
)
181+
]
182+
183+
def get_block_storage_pools(self, project_id):
184+
return [
185+
pool.to_dict(original_names=True) for pool in self.connection.block_storage.pools(project_id, details=True)
186+
]
187+
188+
def get_block_storage_clusters(self, project_id):
189+
return [
190+
cluster.to_dict(original_names=True)
191+
for cluster in self.connection.block_storage.clusters(project_id, details=True)
192+
]
193+
157194
def get_compute_limits(self, project_id):
158195
return self.connection.compute.get_limits(tenant_id=project_id).to_dict(original_names=True)
159196

openstack_controller/datadog_checks/openstack_controller/components/block_storage.py

Lines changed: 108 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,28 @@
55

66
from datadog_checks.openstack_controller.components.component import Component
77
from datadog_checks.openstack_controller.metrics import (
8+
CINDER_CLUSTER_COUNT,
9+
CINDER_CLUSTER_METRICS,
10+
CINDER_CLUSTER_PREFIX,
11+
CINDER_CLUSTER_TAGS,
12+
CINDER_METRICS_PREFIX,
13+
CINDER_POOL_COUNT,
14+
CINDER_POOL_METRICS,
15+
CINDER_POOL_PREFIX,
16+
CINDER_POOL_TAGS,
817
CINDER_RESPONSE_TIME,
918
CINDER_SERVICE_CHECK,
19+
CINDER_SNAPSHOT_COUNT,
20+
CINDER_SNAPSHOT_METRICS,
21+
CINDER_SNAPSHOT_PREFIX,
22+
CINDER_SNAPSHOT_TAGS,
23+
CINDER_TRANSFER_COUNT,
24+
CINDER_TRANSFER_TAGS,
25+
CINDER_VOLUME_COUNT,
26+
CINDER_VOLUME_METRICS,
27+
CINDER_VOLUME_PREFIX,
28+
CINDER_VOLUME_TAGS,
29+
get_metrics_and_tags,
1030
)
1131

1232

@@ -25,3 +45,91 @@ def _report_response_time(self, global_components_config, tags):
2545
response_time = self.check.api.get_response_time(BlockStorage.TYPES.value)
2646
self.check.log.debug("`%s` response time: %s", BlockStorage.ID.value, response_time)
2747
self.check.gauge(CINDER_RESPONSE_TIME, response_time, tags=tags)
48+
49+
@Component.register_project_metrics(ID)
50+
@Component.http_error()
51+
def _report_volumes(self, project_id, tags, config):
52+
report_volumes = config.get('volumes', True)
53+
if report_volumes:
54+
data = self.check.api.get_block_storage_volumes(project_id)
55+
for item in data:
56+
volume = get_metrics_and_tags(
57+
item,
58+
tags=CINDER_VOLUME_TAGS,
59+
prefix=CINDER_VOLUME_PREFIX,
60+
metrics=CINDER_VOLUME_METRICS,
61+
)
62+
self.check.log.debug("volume: %s", volume)
63+
self.check.gauge(CINDER_VOLUME_COUNT, 1, tags=tags + volume['tags'])
64+
for metric, value in volume['metrics'].items():
65+
self.check.gauge(metric, value, tags=tags + volume['tags'])
66+
67+
@Component.register_project_metrics(ID)
68+
@Component.http_error()
69+
def _report_transfers(self, project_id, tags, config):
70+
report_transfers = config.get('transfers', True)
71+
if report_transfers:
72+
data = self.check.api.get_block_storage_transfers(project_id)
73+
for item in data:
74+
transfer = get_metrics_and_tags(
75+
item,
76+
tags=CINDER_TRANSFER_TAGS,
77+
prefix=CINDER_METRICS_PREFIX,
78+
metrics=[CINDER_TRANSFER_COUNT],
79+
)
80+
self.check.log.debug("transfer: %s", transfer)
81+
self.check.gauge(CINDER_TRANSFER_COUNT, 1, tags=tags + transfer['tags'])
82+
83+
@Component.register_project_metrics(ID)
84+
@Component.http_error()
85+
def _report_snapshots(self, project_id, tags, config):
86+
report_snapshots = config.get('snapshots', True)
87+
if report_snapshots:
88+
data = self.check.api.get_block_storage_snapshots(project_id)
89+
for item in data:
90+
snapshot = get_metrics_and_tags(
91+
item,
92+
tags=CINDER_SNAPSHOT_TAGS,
93+
prefix=CINDER_SNAPSHOT_PREFIX,
94+
metrics=CINDER_SNAPSHOT_METRICS,
95+
)
96+
self.check.log.debug("snapshot: %s", snapshot)
97+
self.check.gauge(CINDER_SNAPSHOT_COUNT, 1, tags=tags + snapshot['tags'])
98+
for metric, value in snapshot['metrics'].items():
99+
self.check.gauge(metric, value, tags=tags + snapshot['tags'])
100+
101+
@Component.register_project_metrics(ID)
102+
@Component.http_error()
103+
def _report_pools(self, project_id, tags, config):
104+
report_pools = config.get('pools', True)
105+
if report_pools:
106+
data = self.check.api.get_block_storage_pools(project_id)
107+
for item in data:
108+
pool = get_metrics_and_tags(
109+
item,
110+
tags=CINDER_POOL_TAGS,
111+
prefix=CINDER_POOL_PREFIX,
112+
metrics=CINDER_POOL_METRICS,
113+
)
114+
self.check.log.debug("pool: %s", pool)
115+
self.check.gauge(CINDER_POOL_COUNT, 1, tags=tags + pool['tags'])
116+
for metric, value in pool['metrics'].items():
117+
self.check.gauge(metric, value, tags=tags + pool['tags'])
118+
119+
@Component.register_project_metrics(ID)
120+
@Component.http_error()
121+
def _report_clusters(self, project_id, tags, config):
122+
report_clusters = config.get('clusters', True)
123+
if report_clusters:
124+
data = self.check.api.get_block_storage_clusters(project_id)
125+
for item in data:
126+
cluster = get_metrics_and_tags(
127+
item,
128+
tags=CINDER_CLUSTER_TAGS,
129+
prefix=CINDER_CLUSTER_PREFIX,
130+
metrics=CINDER_CLUSTER_METRICS,
131+
)
132+
self.check.log.debug("cluster: %s", cluster)
133+
self.check.gauge(CINDER_CLUSTER_COUNT, 1, tags=tags + cluster['tags'])
134+
for metric, value in cluster['metrics'].items():
135+
self.check.gauge(metric, value, tags=tags + cluster['tags'])

openstack_controller/datadog_checks/openstack_controller/config.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ def __init__(self, logger, config):
4545
self.user = config.user
4646
self.nova_microversion = config.nova_microversion
4747
self.ironic_microversion = config.ironic_microversion
48+
self.cinder_microversion = config.cinder_microversion
4849
self.endpoint_interface = config.endpoint_interface
4950
self.endpoint_region_id = config.endpoint_region_id
5051
self.paginated_limit = config.paginated_limit
@@ -66,6 +67,9 @@ def validate(self):
6667
if self.ironic_microversion:
6768
self._validate_microversion(self.ironic_microversion, 'ironic')
6869

70+
if self.cinder_microversion:
71+
self._validate_microversion(self.cinder_microversion, 'cinder')
72+
6973
def _validate_microversion(self, microversion, service):
7074
is_latest = microversion.lower() == 'latest'
7175
is_float = False
@@ -79,7 +83,11 @@ def _validate_microversion(self, microversion, service):
7983
is_float = float(microversion)
8084
except Exception:
8185
pass
82-
if not is_latest and not is_float:
86+
if (
87+
not is_latest
88+
and not is_float
89+
and (service != 'cinder' or (service == 'cinder' and 'volume' not in microversion))
90+
):
8391
raise ConfigurationError(
8492
"Invalid `{}_microversion`: {}; please specify a valid version, see the Openstack documentation"
8593
"for more details: https://docs.openstack.org/api-guide/compute/microversions.html".format(

openstack_controller/datadog_checks/openstack_controller/config_models/instance.py

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,18 @@ class BaremetalItem(BaseModel):
5858
nodes: Optional[Union[bool, Node]] = None
5959

6060

61+
class BlockStorageItem(BaseModel):
62+
model_config = ConfigDict(
63+
arbitrary_types_allowed=True,
64+
frozen=True,
65+
)
66+
clusters: Optional[bool] = None
67+
pools: Optional[bool] = None
68+
snapshots: Optional[bool] = None
69+
transfers: Optional[bool] = None
70+
volumes: Optional[bool] = None
71+
72+
6173
class Hypervisor(BaseModel):
6274
model_config = ConfigDict(
6375
arbitrary_types_allowed=True,
@@ -291,7 +303,7 @@ class Components(BaseModel):
291303
frozen=True,
292304
)
293305
baremetal: Optional[Union[bool, BaremetalItem]] = None
294-
block_storage: Optional[Union[bool, MappingProxyType[str, Any]]] = Field(None, alias='block-storage')
306+
block_storage: Optional[Union[bool, BlockStorageItem]] = Field(None, alias='block-storage')
295307
compute: Optional[Union[bool, ComputeItem]] = None
296308
identity: Optional[Union[bool, IdentityItem]] = None
297309
image: Optional[Union[bool, ImageItem]] = None
@@ -342,6 +354,7 @@ class InstanceConfig(BaseModel):
342354
aws_region: Optional[str] = None
343355
aws_service: Optional[str] = None
344356
blacklist_project_names: Optional[tuple[str, ...]] = None
357+
cinder_microversion: Optional[str] = None
345358
collect_hypervisor_load: Optional[bool] = None
346359
collect_hypervisor_metrics: Optional[bool] = None
347360
collect_network_metrics: Optional[bool] = None

openstack_controller/datadog_checks/openstack_controller/data/conf.yaml.example

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,15 @@ instances:
104104
#
105105
nova_microversion: '2.93'
106106

107+
## @param cinder_microversion - string - optional
108+
## The microversion of the Rest API to call.
109+
## It is recommended to set this parameter to the latest microversion supported by your Openstack version.
110+
##
111+
## View this page for more about microvoersion compatibility:
112+
## https://docs.openstack.org/cinder/latest/contributor/api_microversion_history.html
113+
#
114+
cinder_microversion: volume 3.70
115+
107116
## @param use_shortname - boolean - optional - default: false
108117
## In some OpenStack environments, the hostname registered to Nova is the shortname.
109118
## Enabling this enforces the check to split the hostname up to the first period when

openstack_controller/datadog_checks/openstack_controller/metrics.py

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,32 @@
353353

354354
CINDER_METRICS_PREFIX = "openstack.cinder"
355355
CINDER_SERVICE_CHECK = f"{CINDER_METRICS_PREFIX}.api.up"
356+
CINDER_POOL_PREFIX = f"{CINDER_METRICS_PREFIX}.pool"
357+
CINDER_POOL_COUNT = f"{CINDER_POOL_PREFIX}.count"
358+
CINDER_POOL_METRICS = {
359+
f"{CINDER_POOL_PREFIX}.capabilities.total_capacity_gb": {},
360+
f"{CINDER_POOL_PREFIX}.capabilities.free_capacity_gb": {},
361+
f"{CINDER_POOL_PREFIX}.capabilities.reserved_percentage": {},
362+
}
363+
CINDER_POOL_TAGS = {
364+
'name': 'pool_name',
365+
'capabilities.volume_backend_name': 'pool_volume_backend_name',
366+
}
356367
CINDER_RESPONSE_TIME = f"{CINDER_METRICS_PREFIX}.response_time"
368+
CINDER_CLUSTER_PREFIX = f"{CINDER_METRICS_PREFIX}.cluster"
369+
CINDER_CLUSTER_COUNT = f"{CINDER_CLUSTER_PREFIX}.count"
370+
CINDER_CLUSTER_METRICS = {f"{CINDER_CLUSTER_PREFIX}.num_hosts": {}, f"{CINDER_CLUSTER_PREFIX}.num_down_hosts": {}}
371+
CINDER_CLUSTER_TAGS = {'name': 'cluster-name'}
372+
CINDER_SNAPSHOT_PREFIX = f"{CINDER_METRICS_PREFIX}.snapshot"
373+
CINDER_SNAPSHOT_COUNT = f"{CINDER_SNAPSHOT_PREFIX}.count"
374+
CINDER_SNAPSHOT_METRICS = {f"{CINDER_SNAPSHOT_PREFIX}.size": {}}
375+
CINDER_SNAPSHOT_TAGS = {'id': 'snapshot_id', 'volume_id': 'volume_id'}
376+
CINDER_TRANSFER_COUNT = f"{CINDER_METRICS_PREFIX}.volume.transfer.count"
377+
CINDER_TRANSFER_TAGS = {'id': 'transfer_id', 'volume_id': 'volume_id', 'name': 'volume_name'}
378+
CINDER_VOLUME_PREFIX = f"{CINDER_METRICS_PREFIX}.volume"
379+
CINDER_VOLUME_COUNT = f"{CINDER_VOLUME_PREFIX}.count"
380+
CINDER_VOLUME_METRICS = {f"{CINDER_VOLUME_PREFIX}.size": {}}
381+
CINDER_VOLUME_TAGS = {'id': 'volume_id', 'name': 'volume_name', 'status': 'volume_status'}
357382

358383
IRONIC_METRICS_PREFIX = "openstack.ironic"
359384
IRONIC_SERVICE_CHECK = f"{IRONIC_METRICS_PREFIX}.api.up"

0 commit comments

Comments
 (0)