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

ManagedInstanceResource.GetTopQueries 方法

定义

重载

GetTopQueries(ManagedInstanceResourceGetTopQueriesOptions, CancellationToken)

获取托管实例资源消耗量最大的查询。

  • 请求路径/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/topqueries
  • 操作IdManagedInstances_ListByManagedInstance
GetTopQueries(Nullable<Int32>, String, String, String, Nullable<QueryTimeGrainType>, Nullable<AggregationFunctionType>, Nullable<SqlMetricType>, CancellationToken)

获取托管实例资源消耗量最大的查询。

  • 请求路径/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/topqueries
  • 操作IdManagedInstances_ListByManagedInstance

GetTopQueries(ManagedInstanceResourceGetTopQueriesOptions, CancellationToken)

获取托管实例资源消耗量最大的查询。

  • 请求路径/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/topqueries
  • 操作IdManagedInstances_ListByManagedInstance
public virtual Azure.Pageable<Azure.ResourceManager.Sql.Models.TopQueries> GetTopQueries (Azure.ResourceManager.Sql.Models.ManagedInstanceResourceGetTopQueriesOptions options, System.Threading.CancellationToken cancellationToken = default);
abstract member GetTopQueries : Azure.ResourceManager.Sql.Models.ManagedInstanceResourceGetTopQueriesOptions * System.Threading.CancellationToken -> Azure.Pageable<Azure.ResourceManager.Sql.Models.TopQueries>
override this.GetTopQueries : Azure.ResourceManager.Sql.Models.ManagedInstanceResourceGetTopQueriesOptions * System.Threading.CancellationToken -> Azure.Pageable<Azure.ResourceManager.Sql.Models.TopQueries>
Public Overridable Function GetTopQueries (options As ManagedInstanceResourceGetTopQueriesOptions, Optional cancellationToken As CancellationToken = Nothing) As Pageable(Of TopQueries)

参数

options
ManagedInstanceResourceGetTopQueriesOptions

包含此方法的所有参数(LRO 限定符和请求上下文参数除外)的属性包。

cancellationToken
CancellationToken

要使用的取消标记。

返回

的集合 TopQueries ,可能需要多个服务请求才能循环访问。

适用于

GetTopQueries(Nullable<Int32>, String, String, String, Nullable<QueryTimeGrainType>, Nullable<AggregationFunctionType>, Nullable<SqlMetricType>, CancellationToken)

获取托管实例资源消耗量最大的查询。

  • 请求路径/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/topqueries
  • 操作IdManagedInstances_ListByManagedInstance
public virtual Azure.Pageable<Azure.ResourceManager.Sql.Models.TopQueries> GetTopQueries (int? numberOfQueries = default, string databases = default, string startTime = default, string endTime = default, Azure.ResourceManager.Sql.Models.QueryTimeGrainType? interval = default, Azure.ResourceManager.Sql.Models.AggregationFunctionType? aggregationFunction = default, Azure.ResourceManager.Sql.Models.SqlMetricType? observationMetric = default, System.Threading.CancellationToken cancellationToken = default);
abstract member GetTopQueries : Nullable<int> * string * string * string * Nullable<Azure.ResourceManager.Sql.Models.QueryTimeGrainType> * Nullable<Azure.ResourceManager.Sql.Models.AggregationFunctionType> * Nullable<Azure.ResourceManager.Sql.Models.SqlMetricType> * System.Threading.CancellationToken -> Azure.Pageable<Azure.ResourceManager.Sql.Models.TopQueries>
override this.GetTopQueries : Nullable<int> * string * string * string * Nullable<Azure.ResourceManager.Sql.Models.QueryTimeGrainType> * Nullable<Azure.ResourceManager.Sql.Models.AggregationFunctionType> * Nullable<Azure.ResourceManager.Sql.Models.SqlMetricType> * System.Threading.CancellationToken -> Azure.Pageable<Azure.ResourceManager.Sql.Models.TopQueries>
Public Overridable Function GetTopQueries (Optional numberOfQueries As Nullable(Of Integer) = Nothing, Optional databases As String = Nothing, Optional startTime As String = Nothing, Optional endTime As String = Nothing, Optional interval As Nullable(Of QueryTimeGrainType) = Nothing, Optional aggregationFunction As Nullable(Of AggregationFunctionType) = Nothing, Optional observationMetric As Nullable(Of SqlMetricType) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Pageable(Of TopQueries)

参数

numberOfQueries
Nullable<Int32>

要返回的“排名靠前的查询”数。 默认值为 5。

databases
String

要包含在搜索中的数据库的逗号分隔列表。 如果未指定此参数,则包含所有 DB 的 。

startTime
String

观察到的时间段的开始时间。

endTime
String

观察到的时间段的结束时间。

interval
Nullable<QueryTimeGrainType>

用于汇总指标值的时间步长。 默认值为 PT1H。

aggregationFunction
Nullable<AggregationFunctionType>

要使用的聚合函数,默认值为“sum”。

observationMetric
Nullable<SqlMetricType>

用于排名靠前的查询的指标。 默认值为“cpu”。

cancellationToken
CancellationToken

要使用的取消标记。

返回

的集合 TopQueries ,可能需要多个服务请求才能循环访问。

适用于