-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Closed
Closed
Copy link
Labels
ClientThis issue points to a problem in the data-plane of the library.This issue points to a problem in the data-plane of the library.MonitorMonitor, Monitor Ingestion, Monitor QueryMonitor, Monitor Ingestion, Monitor Querycustomer-reportedIssues that are reported by GitHub users external to the Azure organization.Issues that are reported by GitHub users external to the Azure organization.issue-addressedWorkflow: The Azure SDK team believes it to be addressed and ready to close.Workflow: The Azure SDK team believes it to be addressed and ready to close.questionThe issue doesn't require a change to the product in order to be resolved. Most issues start as thatThe issue doesn't require a change to the product in order to be resolved. Most issues start as that
Milestone
Description
- Package Name: azure-monitor-query
- Package Version: 1.0.0
- Operating System: Mac OS 11.4
- Python Version: 3.9.7
Describe the bug
I am trying to get the eventhub namespace metrics split by the eventhub name. Therefore I am using * as the filter value: entityname eq '*'.
The returned data is indeed split by the entity name. However there is no metadata provided. So I am not able to understand
what entities the values belong too.
To Reproduce
I am using this code:
metrics_uri = os.environ['METRICS_RESOURCE_URI']
response = client.query_resource(
metrics_uri,
metric_names=["IncomingMessages"],
timespan=timedelta(days=1),
granularity=timedelta(hours=24),
filter="entityname eq '*'",
aggregation='Total'
)
for metric in response.metrics:
print(metric.name + ' -- ' + metric.display_description)
for time_series_element in metric.timeseries:
print(f"Metadata {time_series_element.metadata_values}")
for metric_value in time_series_element.data:
print(f"{metric_value.timestamp} -- {metric_value.total}")METRICS_RESOURCE_URI is the the eventhub namespace.
Expected behavior
Metadata is returned and contains the name of the event hub.
Screenshots
Here is the output from the above code
Additional context
The metadata is returned correctly with Azure CLI
Metadata
Metadata
Assignees
Labels
ClientThis issue points to a problem in the data-plane of the library.This issue points to a problem in the data-plane of the library.MonitorMonitor, Monitor Ingestion, Monitor QueryMonitor, Monitor Ingestion, Monitor Querycustomer-reportedIssues that are reported by GitHub users external to the Azure organization.Issues that are reported by GitHub users external to the Azure organization.issue-addressedWorkflow: The Azure SDK team believes it to be addressed and ready to close.Workflow: The Azure SDK team believes it to be addressed and ready to close.questionThe issue doesn't require a change to the product in order to be resolved. Most issues start as thatThe issue doesn't require a change to the product in order to be resolved. Most issues start as that
