[GCP] gcp.metrics
always filter on resource.labels.zone
even when only region
is specified in the config file
#33118
Labels
While working on #32943 @gpop63 correctly noticed that in
gcp.metrics
metricset in the metrics filter creation function in the default filter case we only rely onresource.labels.zone
, not usingresource.labels.region
even whenregion
is the only setting specified in the metricset configuration.beats/x-pack/metricbeat/module/gcp/metrics/metrics_requester.go
Lines 199 to 207 in 867ad49
In GCP some services/resources can be of 3 types: global (available globally), regional (available in specific regions) or zonal (available in multiple zones within a region and multiple regions).
Depending on the type of the service the
resource.labels
map contains different keys, and from my understanding this code may results in bugs when usingregion
setting for regional services.The text was updated successfully, but these errors were encountered: