Package com.azure.monitor.query
Class MetricsBatchQueryClient
java.lang.Object
com.azure.monitor.query.MetricsBatchQueryClient
This class provides an asynchronous client that contains all the query operations that use batch requests to retrieve
metrics for multiple resources.
-
Method Summary
Modifier and TypeMethodDescriptionReturns all the Azure Monitor metrics requested for the batch of resources.com.azure.core.http.rest.Response<MetricsBatchResult>queryBatchWithResponse(List<String> resourceUris, List<String> metricsNames, String metricsNamespace, MetricsQueryOptions options, com.azure.core.util.Context context) Returns all the Azure Monitor metrics requested for the batch of resources.
-
Method Details
-
queryBatch
public MetricsBatchResult queryBatch(List<String> resourceUris, List<String> metricsNames, String metricsNamespace) Returns all the Azure Monitor metrics requested for the batch of resources.- Parameters:
resourceUris- The resource URIs for which the metrics is requested.metricsNames- The names of the metrics to query.metricsNamespace- The namespace of the metrics to query.- Returns:
- A time-series metrics result for the requested metric names.
-
queryBatchWithResponse
public com.azure.core.http.rest.Response<MetricsBatchResult> queryBatchWithResponse(List<String> resourceUris, List<String> metricsNames, String metricsNamespace, MetricsQueryOptions options, com.azure.core.util.Context context) Returns all the Azure Monitor metrics requested for the batch of resources.- Parameters:
resourceUris- The resource URIs for which the metrics is requested.metricsNames- The names of the metrics to query.metricsNamespace- The namespace of the metrics to query.options- TheMetricsQueryOptionsto include for the request.context- The context to associate with this operation.- Returns:
- A time-series metrics result for the requested metric names.
- Throws:
IllegalArgumentException- thrown ifresourceUris,metricsNamesormetricsNamespaceare empty.NullPointerException- thrown ifresourceUris,metricsNamesormetricsNamespaceare null.
-