MetricBaselineOperations Class

MetricBaselineOperations async operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Inheritance
builtins.object
MetricBaselineOperations

Constructor

MetricBaselineOperations(client, config, serializer, deserializer)

Parameters

client
Required

Client for service requests.

config
Required

Configuration of service client.

serializer
Required

An object model serializer.

deserializer
Required

An object model deserializer.

Variables

models

Alias to model classes used in this operation group.

Methods

calculate_baseline

Lists the baseline values for a resource.

get

Gets the baseline values for a specific metric.

calculate_baseline

Lists the baseline values for a resource.

async calculate_baseline(resource_uri: str, time_series_information: azure.mgmt.monitor.v2017_11_01_preview.models._models_py3.TimeSeriesInformation, **kwargs: Any) -> azure.mgmt.monitor.v2017_11_01_preview.models._models_py3.CalculateBaselineResponse

Parameters

resource_uri
str
Required

The identifier of the resource. It has the following structure: subscriptions/{subscriptionName}/resourceGroups/{resourceGroupName}/providers/{providerName}/{resourceName}. For example: subscriptions/b368ca2f-e298-46b7-b0ab-012281956afa/resourceGroups/vms/providers/Microsoft.Compute/virtualMachines/vm1.

time_series_information
<xref:$>(<xref:python-base-namespace>)TimeSeriesInformation
Required

Information that need to be specified to calculate a baseline on a time series.

cls
callable

A custom type or function that will be passed the direct response

Returns

CalculateBaselineResponse, or the result of cls(response)

Return type

<xref:$>(<xref:python-base-namespace>)CalculateBaselineResponse

Exceptions

get

Gets the baseline values for a specific metric.

async get(resource_uri: str, metric_name: str, timespan: Optional[str] = None, interval: Optional[datetime.timedelta] = None, aggregation: Optional[str] = None, sensitivities: Optional[str] = None, result_type: Optional[Union[str, azure.mgmt.monitor.v2017_11_01_preview.models._monitor_management_client_enums.ResultType]] = None, **kwargs: Any) -> azure.mgmt.monitor.v2017_11_01_preview.models._models_py3.BaselineResponse

Parameters

resource_uri
str
Required

The identifier of the resource. It has the following structure: subscriptions/{subscriptionName}/resourceGroups/{resourceGroupName}/providers/{providerName}/{resourceName}. For example: subscriptions/b368ca2f-e298-46b7-b0ab-012281956afa/resourceGroups/vms/providers/Microsoft.Compute/virtualMachines/vm1.

metric_name
str
Required

The name of the metric to retrieve the baseline for.

timespan
str
Required

The timespan of the query. It is a string with the following format 'startDateTime_ISO/endDateTime_ISO'.

interval
timedelta
Required

The interval (i.e. timegrain) of the query.

aggregation
str
Required

The aggregation type of the metric to retrieve the baseline for.

sensitivities
str
Required

The list of sensitivities (comma separated) to retrieve.

result_type
str or <xref:$>(<xref:python-base-namespace>)ResultType
Required

Allows retrieving only metadata of the baseline. On data request all information is retrieved.

cls
callable

A custom type or function that will be passed the direct response

Returns

BaselineResponse, or the result of cls(response)

Return type

<xref:$>(<xref:python-base-namespace>)BaselineResponse

Exceptions

Attributes

models

models = <module 'azure.mgmt.monitor.v2017_11_01_preview.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.9.13\\x64\\lib\\site-packages\\azure\\mgmt\\monitor\\v2017_11_01_preview\\models\\__init__.py'>