MetricsQueryClient.GetMetricDefinitions Methode

Definition

Ruft Metrikdefinitionen für eine bestimmte Ressource und einen bestimmten Metriknamespace ab.

public virtual Azure.Pageable<Azure.Monitor.Query.Models.MetricDefinition> GetMetricDefinitions (string resourceId, string metricsNamespace, System.Threading.CancellationToken cancellationToken = default);
abstract member GetMetricDefinitions : string * string * System.Threading.CancellationToken -> Azure.Pageable<Azure.Monitor.Query.Models.MetricDefinition>
override this.GetMetricDefinitions : string * string * System.Threading.CancellationToken -> Azure.Pageable<Azure.Monitor.Query.Models.MetricDefinition>
Public Overridable Function GetMetricDefinitions (resourceId As String, metricsNamespace As String, Optional cancellationToken As CancellationToken = Nothing) As Pageable(Of MetricDefinition)

Parameter

resourceId
String

Der Name der Ressource. Beispiel: /subscriptions/<subscription_id>/resourceGroups/<resource_group_name>/providers/<resource_provider>/<resource>,
/subscriptions/faa080af-c1d8-40ad-9cce-e1a450ca5b57/resourceGroups/resource-group/providers/Microsoft.Storage/storageAccounts/mystorage,
/subscriptions/faa080af-c1d8-40ad-9cce-e1a450ca5b57/resourceGroups/resource-group/providers/Microsoft.Compute/virtualMachines/myvm

metricsNamespace
String

Der Metriknamespace. Beispiel: Microsoft.OperationalInsights/workspaces

cancellationToken
CancellationToken

Der zu verwendende CancellationToken.

Gibt zurück

Eine auslagerungsfähige Auflistung von Metrikdefinitionen.

Gilt für: