Show / Hide Table of Contents

    Class MetricTrigger

    The trigger that results in a scaling action.

    Inheritance
    Object
    MetricTrigger
    Namespace: System.Dynamic.ExpandoObject
    Assembly: Microsoft.Azure.Management.Monitor.dll
    Syntax
    public class MetricTrigger

    Constructors

    MetricTrigger()

    Initializes a new instance of the MetricTrigger class.

    Declaration
    public MetricTrigger ();

    MetricTrigger(String, String, TimeSpan, MetricStatisticType, TimeSpan, TimeAggregationType, ComparisonOperationType, Double)

    Initializes a new instance of the MetricTrigger class.

    Declaration
    public MetricTrigger (string metricName, string metricResourceUri, TimeSpan timeGrain, Microsoft.Azure.Management.Monitor.Models.MetricStatisticType statistic, TimeSpan timeWindow, Microsoft.Azure.Management.Monitor.Models.TimeAggregationType timeAggregation, Microsoft.Azure.Management.Monitor.Models.ComparisonOperationType operatorProperty, double threshold);
    Parameters
    String metricName

    the name of the metric that defines what the rule monitors.

    String metricResourceUri

    the resource identifier of the resource the rule monitors.

    TimeSpan timeGrain

    the granularity of metrics the rule monitors. Must be one of the predefined values returned from metric definitions for the metric. Must be between 12 hours and 1 minute.

    MetricStatisticType statistic

    the metric statistic type. How the metrics from multiple instances are combined. Possible values include: 'Average', 'Min', 'Max', 'Sum'

    TimeSpan timeWindow

    the range of time in which instance data is collected. This value must be greater than the delay in metric collection, which can vary from resource-to-resource. Must be between 12 hours and 5 minutes.

    TimeAggregationType timeAggregation

    time aggregation type. How the data that is collected should be combined over time. The default value is Average. Possible values include: 'Average', 'Minimum', 'Maximum', 'Total', 'Count', 'Last'

    ComparisonOperationType operatorProperty

    the operator that is used to compare the metric data and the threshold. Possible values include: 'Equals', 'NotEquals', 'GreaterThan', 'GreaterThanOrEqual', 'LessThan', 'LessThanOrEqual'

    Double threshold

    the threshold of the metric that triggers the scale action.

    Properties

    MetricName

    Gets or sets the name of the metric that defines what the rule monitors.

    Declaration
    [Newtonsoft.Json.JsonProperty(PropertyName="metricName")]
    public string MetricName { get; set; }
    Property Value
    String

    MetricResourceUri

    Gets or sets the resource identifier of the resource the rule monitors.

    Declaration
    [Newtonsoft.Json.JsonProperty(PropertyName="metricResourceUri")]
    public string MetricResourceUri { get; set; }
    Property Value
    String

    OperatorProperty

    Gets or sets the operator that is used to compare the metric data and the threshold. Possible values include: 'Equals', 'NotEquals', 'GreaterThan', 'GreaterThanOrEqual', 'LessThan', 'LessThanOrEqual'

    Declaration
    [Newtonsoft.Json.JsonProperty(PropertyName="operator")]
    public Microsoft.Azure.Management.Monitor.Models.ComparisonOperationType OperatorProperty { get; set; }
    Property Value
    ComparisonOperationType

    Statistic

    Gets or sets the metric statistic type. How the metrics from multiple instances are combined. Possible values include: 'Average', 'Min', 'Max', 'Sum'

    Declaration
    [Newtonsoft.Json.JsonProperty(PropertyName="statistic")]
    public Microsoft.Azure.Management.Monitor.Models.MetricStatisticType Statistic { get; set; }
    Property Value
    MetricStatisticType

    Threshold

    Gets or sets the threshold of the metric that triggers the scale action.

    Declaration
    [Newtonsoft.Json.JsonProperty(PropertyName="threshold")]
    public double Threshold { get; set; }
    Property Value
    Double

    TimeAggregation

    Gets or sets time aggregation type. How the data that is collected should be combined over time. The default value is Average. Possible values include: 'Average', 'Minimum', 'Maximum', 'Total', 'Count', 'Last'

    Declaration
    [Newtonsoft.Json.JsonProperty(PropertyName="timeAggregation")]
    public Microsoft.Azure.Management.Monitor.Models.TimeAggregationType TimeAggregation { get; set; }
    Property Value
    TimeAggregationType

    TimeGrain

    Gets or sets the granularity of metrics the rule monitors. Must be one of the predefined values returned from metric definitions for the metric. Must be between 12 hours and 1 minute.

    Declaration
    [Newtonsoft.Json.JsonProperty(PropertyName="timeGrain")]
    public TimeSpan TimeGrain { get; set; }
    Property Value
    TimeSpan

    TimeWindow

    Gets or sets the range of time in which instance data is collected. This value must be greater than the delay in metric collection, which can vary from resource-to-resource. Must be between 12 hours and 5 minutes.

    Declaration
    [Newtonsoft.Json.JsonProperty(PropertyName="timeWindow")]
    public TimeSpan TimeWindow { get; set; }
    Property Value
    TimeSpan

    Methods

    Validate()

    Validate the object.

    Declaration
    public virtual void Validate ();
    Exceptions
    ValidationException

    Thrown if validation fails

    Back to top Azure SDK for Net