你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

IBaselinesOperations.ListWithHttpMessagesAsync 方法

定义

列出资源的指标基线值

public System.Threading.Tasks.Task<Microsoft.Rest.Azure.AzureOperationResponse<System.Collections.Generic.IEnumerable<Microsoft.Azure.Management.Monitor.Models.SingleMetricBaseline>>> ListWithHttpMessagesAsync (string resourceUri, string metricnames = default, string metricnamespace = default, string timespan = default, TimeSpan? interval = default, string aggregation = default, string sensitivities = default, string filter = default, Microsoft.Azure.Management.Monitor.Models.ResultType? resultType = default, System.Collections.Generic.Dictionary<string,System.Collections.Generic.List<string>> customHeaders = default, System.Threading.CancellationToken cancellationToken = default);
abstract member ListWithHttpMessagesAsync : string * string * string * string * Nullable<TimeSpan> * string * string * string * Nullable<Microsoft.Azure.Management.Monitor.Models.ResultType> * System.Collections.Generic.Dictionary<string, System.Collections.Generic.List<string>> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Rest.Azure.AzureOperationResponse<seq<Microsoft.Azure.Management.Monitor.Models.SingleMetricBaseline>>>
Public Function ListWithHttpMessagesAsync (resourceUri As String, Optional metricnames As String = Nothing, Optional metricnamespace As String = Nothing, Optional timespan As String = Nothing, Optional interval As Nullable(Of TimeSpan) = Nothing, Optional aggregation As String = Nothing, Optional sensitivities As String = Nothing, Optional filter As String = Nothing, Optional resultType As Nullable(Of ResultType) = Nothing, Optional customHeaders As Dictionary(Of String, List(Of String)) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of AzureOperationResponse(Of IEnumerable(Of SingleMetricBaseline)))

参数

resourceUri
String

资源的标识符。

metricnames
String

要检索的指标名称 (逗号分隔) 。 特殊情况:如果指标名称本身包含逗号,则使用 %2 来指示它。 例如:“Metric,Name1”应为 “Metric%2Name1”

metricnamespace
String

要查询其指标定义的指标命名空间。

timespan
String

查询的时间跨度。 它是格式为“startDateTime_ISO/endDateTime_ISO”的字符串。

interval
Nullable<TimeSpan>

间隔 (即查询的 timegrain) 。

aggregation
String

要检索的聚合类型列表 (逗号分隔) 。

sensitivities
String

要检索的敏感度列表 (逗号分隔) 。

filter
String

$filter用于减少返回的指标数据集。 示例:指标包含元数据 A、B 和 C。 - 返回 C 的所有时序,其中 A = a1 且 B = b1 或 b2 $filter=A eq 'a1' 和 B eq 'b1' 或 B eq 'b2' 和 C eq '*' - 无效的变量: $filter=A eq 'a1' 和 B eq 'b1' 和 C eq '*' 或 B = 'b2' 这无效,因为逻辑或运算符无法分隔两个不同的元数据名称。 - 返回 A = a1、B = b1 且 C = c1 的所有时序: $filter=A eq 'a1' 和 B eq 'b1' 和 C eq 'c1' - 返回 A = a1 $filter=A eq 'a1' 和 B eq '' 和 C eq ''的所有时序。 特殊情况:当维度名称或维度值使用圆括号时。 例如:当维度名称 为 dim (test) 1 而不是使用 $filter= “dim (test) 1 eq '” 时,请使用 **$filter= “dim %2528test%2529 1 eq '' ”** 当维度名称为 dim 时, (测试) 3 且维度值为 dim3 (test) val 而不是使用 $filter= “dim (test) 3 eq 'dim3 (test) val' ” use $filter= “dim %2528test%2529 3 eq 'dim3 %2528test%2529 val' ”

resultType
Nullable<ResultType>

仅允许检索基线的元数据。 在数据请求中检索所有信息。 可能的值包括:“Data”、“Metadata”

customHeaders
Dictionary<String,List<String>>

将添加到请求的标头。

cancellationToken
CancellationToken

取消标记。

返回

例外

当操作返回无效状态代码时引发

无法反序列化响应时引发

当所需参数为 null 时引发

适用于