We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi, I am using CollectionPartitionOperations -> list_metrics.
metrics = client.collection_partition.list_metrics( resource_group, account_name, database_rid, container_rid, "(name.value eq 'Data Size') and timeGrain eq duration'P1D' and startTime eq '2023-01-01T13:53:55.2780000Z' and endTime eq '2023-01-31T15:58:55.2780000Z'" ) for metric in metrics: print(metric)
Not printing anything.
I set 80,000 throughputs in my container.
We are using: Python Azure SDK - azure-mgmt-cosmosdb==6.4.0 The document we follow: https://learn.microsoft.com/en-us/python/api/azure-mgmt-cosmosdb/azure.mgmt.cosmosdb.operations.collectionpartitionoperations?view=azure-python
The text was updated successfully, but these errors were encountered:
Please follow the below sample to correctly get the list_metrics.
https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/cosmos/azure-mgmt-cosmosdb/generated_samples/cosmos_db_collection_get_metrics.py
The code should be like this:
metrics = client.collection_partition.list_metrics( resource_group, account_name, database_rid, container_rid, "$filter=(name.value eq 'Data Size') and timeGrain eq duration'P1D' and startTime eq '2023-01-01T13:53:55.2780000Z' and endTime eq '2023-01-31T15:58:55.2780000Z'" ) for metric in metrics: print(metric)
You have to include the "$filter=" in the filter string.
Sorry, something went wrong.
I got this issue:
HttpResponseError: (BadRequest) Failed to parse query $filter=(value eq 'data size') and timegrain eq 'p1d' and starttime eq '2023-01-01t13:53:55.2780000z' and endtime eq '2023-01-31t15:58:55.2780000z' ActivityId: c6a9ae91-a912-11ed-b4cf-5414f357addb, Microsoft.Azure.Documents.Common/2.14.0 Code: BadRequest Message: Failed to parse query $filter=(value eq 'data size') and timegrain eq 'p1d' and starttime eq '2023-01-01t13:53:55.2780000z' and endtime eq '2023-01-31t15:58:55.2780000z' ActivityId: c6a9ae91-a912-11ed-b4cf-5414f357addb, Microsoft.Azure.Documents.Common/2.14.0
No branches or pull requests
Hi,
I am using CollectionPartitionOperations -> list_metrics.
Not printing anything.
I set 80,000 throughputs in my container.
We are using:
Python Azure SDK - azure-mgmt-cosmosdb==6.4.0
The document we follow:
https://learn.microsoft.com/en-us/python/api/azure-mgmt-cosmosdb/azure.mgmt.cosmosdb.operations.collectionpartitionoperations?view=azure-python
The text was updated successfully, but these errors were encountered: