Autoscale Settings - Get

Gets an autoscale setting

GET https://management.azure.com/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/microsoft.insights/autoscalesettings/{autoscaleSettingName}?api-version=2015-04-01

URI Parameters

Name In Required Type Description
subscriptionId
path True
  • string

The Azure subscription Id.

resourceGroupName
path True
  • string

The name of the resource group.

autoscaleSettingName
path True
  • string

The autoscale setting name.

api-version
query True
  • string

Client Api Version.

Responses

Name Type Description
200 OK

Successful request to get one autoscale setting

Other Status Codes

Error response describing why the operation failed.

Security

azure_auth

Azure Active Directory OAuth2 Flow

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
user_impersonation impersonate your user account

Examples

Get an autoscale setting

Sample Request

GET https://management.azure.com/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourcegroups/TestingMetricsScaleSet/providers/microsoft.insights/autoscalesettings/MySetting?api-version=2015-04-01

Sample Response

{
  "id": "/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/TestingMetricsScaleSet/providers/microsoft.insights/autoscalesettings/MySetting",
  "name": "MySetting",
  "type": "Microsoft.Insights/autoscaleSettings",
  "location": "West US",
  "tags": {
    "$type": "Microsoft.WindowsAzure.Management.Common.Storage.CasePreservedDictionary, Microsoft.WindowsAzure.Management.Common.Storage"
  },
  "properties": {
    "profiles": [
      {
        "name": "adios",
        "capacity": {
          "minimum": "1",
          "maximum": "10",
          "default": "1"
        },
        "rules": [
          {
            "metricTrigger": {
              "metricName": "Percentage CPU",
              "metricResourceUri": "/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/TestingMetricsScaleSet/providers/Microsoft.Compute/virtualMachineScaleSets/testingsc",
              "timeGrain": "PT1M",
              "statistic": "Average",
              "timeWindow": "PT5M",
              "timeAggregation": "Average",
              "operator": "GreaterThan",
              "threshold": 10
            },
            "scaleAction": {
              "direction": "Increase",
              "type": "ChangeCount",
              "value": "1",
              "cooldown": "PT5M"
            }
          },
          {
            "metricTrigger": {
              "metricName": "Percentage CPU",
              "metricResourceUri": "/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/TestingMetricsScaleSet/providers/Microsoft.Compute/virtualMachineScaleSets/testingsc",
              "timeGrain": "PT2M",
              "statistic": "Average",
              "timeWindow": "PT5M",
              "timeAggregation": "Average",
              "operator": "GreaterThan",
              "threshold": 15
            },
            "scaleAction": {
              "direction": "Decrease",
              "type": "ChangeCount",
              "value": "2",
              "cooldown": "PT6M"
            }
          }
        ],
        "fixedDate": {
          "timeZone": "UTC",
          "start": "2015-03-05T14:00:00Z",
          "end": "2015-03-05T14:30:00Z"
        }
      },
      {
        "name": "saludos",
        "capacity": {
          "minimum": "1",
          "maximum": "10",
          "default": "1"
        },
        "rules": [
          {
            "metricTrigger": {
              "metricName": "Percentage CPU",
              "metricResourceUri": "/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/TestingMetricsScaleSet/providers/Microsoft.Compute/virtualMachineScaleSets/testingsc",
              "timeGrain": "PT1M",
              "statistic": "Average",
              "timeWindow": "PT5M",
              "timeAggregation": "Average",
              "operator": "GreaterThan",
              "threshold": 10
            },
            "scaleAction": {
              "direction": "Increase",
              "type": "ChangeCount",
              "value": "1",
              "cooldown": "PT5M"
            }
          },
          {
            "metricTrigger": {
              "metricName": "Percentage CPU",
              "metricResourceUri": "/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/TestingMetricsScaleSet/providers/Microsoft.Compute/virtualMachineScaleSets/testingsc",
              "timeGrain": "PT2M",
              "statistic": "Average",
              "timeWindow": "PT5M",
              "timeAggregation": "Average",
              "operator": "GreaterThan",
              "threshold": 15
            },
            "scaleAction": {
              "direction": "Decrease",
              "type": "ChangeCount",
              "value": "2",
              "cooldown": "PT6M"
            }
          }
        ],
        "recurrence": {
          "frequency": "Week",
          "schedule": {
            "timeZone": "UTC",
            "days": [
              "1"
            ],
            "hours": [
              5
            ],
            "minutes": [
              15
            ]
          }
        }
      }
    ],
    "enabled": true,
    "name": "MySetting",
    "targetResourceUri": "/subscriptions/b67f7fec-69fc-4974-9099-a26bd6ffeda3/resourceGroups/TestingMetricsScaleSet/providers/Microsoft.Compute/virtualMachineScaleSets/testingsc",
    "notifications": [
      {
        "operation": "Scale",
        "email": {
          "sendToSubscriptionAdministrator": true,
          "sendToSubscriptionCoAdministrators": true,
          "customEmails": [
            "gu@ms.com",
            "ge@ns.net"
          ]
        },
        "webhooks": [
          {
            "serviceUri": "http://myservice.com",
            "properties": {}
          }
        ]
      }
    ]
  }
}

Definitions

AutoscaleNotification

Autoscale notification.

AutoscaleProfile

Autoscale profile.

AutoscaleSettingResource

The autoscale setting resource.

ComparisonOperationType

the operator that is used to compare the metric data and the threshold.

EmailNotification

Email notification of an autoscale event.

ErrorResponse

Describes the format of Error response.

MetricStatisticType

the metric statistic type. How the metrics from multiple instances are combined.

MetricTrigger

The trigger that results in a scaling action.

OperationType

the operation associated with the notification and its value must be "scale"

Recurrence

The repeating times at which this profile begins. This element is not used if the FixedDate element is used.

RecurrenceFrequency

the recurrence frequency. How often the schedule profile should take effect. This value must be Week, meaning each week will have the same set of profiles. For example, to set a daily schedule, set schedule to every day of the week. The frequency property specifies that the schedule is repeated weekly.

RecurrentSchedule

The scheduling constraints for when the profile begins.

ScaleAction

The parameters for the scaling action.

ScaleCapacity

The number of instances that can be used during this profile.

ScaleDirection

the scale direction. Whether the scaling action increases or decreases the number of instances.

ScaleRule

A rule that provide the triggers and parameters for the scaling action.

ScaleType

the type of action that should occur when the scale rule fires.

TimeAggregationType

time aggregation type. How the data that is collected should be combined over time. The default value is Average.

TimeWindow

A specific date-time for the profile.

WebhookNotification

Webhook notification of an autoscale event.

AutoscaleNotification

Autoscale notification.

Name Type Description
email

the email notification.

operation

the operation associated with the notification and its value must be "scale"

webhooks

the collection of webhook notifications.

AutoscaleProfile

Autoscale profile.

Name Type Description
capacity

the number of instances that can be used during this profile.

fixedDate

the specific date-time for the profile. This element is not used if the Recurrence element is used.

name
  • string

the name of the profile.

recurrence

the repeating times at which this profile begins. This element is not used if the FixedDate element is used.

rules

the collection of rules that provide the triggers and parameters for the scaling action. A maximum of 10 rules can be specified.

AutoscaleSettingResource

The autoscale setting resource.

Name Type Description
id
  • string

Azure resource Id

location
  • string

Resource location

name
  • string

Azure resource name

properties.enabled
  • boolean

the enabled flag. Specifies whether automatic scaling is enabled for the resource. The default value is 'true'.

properties.name
  • string

the name of the autoscale setting.

properties.notifications

the collection of notifications.

properties.profiles

the collection of automatic scaling profiles that specify different scaling parameters for different time periods. A maximum of 20 profiles can be specified.

properties.targetResourceUri
  • string

the resource identifier of the resource that the autoscale setting should be added to.

tags
  • object

Resource tags

type
  • string

Azure resource type

ComparisonOperationType

the operator that is used to compare the metric data and the threshold.

Name Type Description
Equals
  • string
GreaterThan
  • string
GreaterThanOrEqual
  • string
LessThan
  • string
LessThanOrEqual
  • string
NotEquals
  • string

EmailNotification

Email notification of an autoscale event.

Name Type Description
customEmails
  • string[]

the custom e-mails list. This value can be null or empty, in which case this attribute will be ignored.

sendToSubscriptionAdministrator
  • boolean

a value indicating whether to send email to subscription administrator.

sendToSubscriptionCoAdministrators
  • boolean

a value indicating whether to send email to subscription co-administrators.

ErrorResponse

Describes the format of Error response.

Name Type Description
code
  • string

Error code

message
  • string

Error message indicating why the operation failed.

MetricStatisticType

the metric statistic type. How the metrics from multiple instances are combined.

Name Type Description
Average
  • string
Max
  • string
Min
  • string
Sum
  • string

MetricTrigger

The trigger that results in a scaling action.

Name Type Description
metricName
  • string

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

metricResourceUri
  • string

the resource identifier of the resource the rule monitors.

operator

the operator that is used to compare the metric data and the threshold.

statistic

the metric statistic type. How the metrics from multiple instances are combined.

threshold
  • number

the threshold of the metric that triggers the scale action.

timeAggregation

time aggregation type. How the data that is collected should be combined over time. The default value is Average.

timeGrain
  • string

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.

timeWindow
  • string

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.

OperationType

the operation associated with the notification and its value must be "scale"

Name Type Description
Scale
  • string

Recurrence

The repeating times at which this profile begins. This element is not used if the FixedDate element is used.

Name Type Description
frequency

the recurrence frequency. How often the schedule profile should take effect. This value must be Week, meaning each week will have the same set of profiles. For example, to set a daily schedule, set schedule to every day of the week. The frequency property specifies that the schedule is repeated weekly.

schedule

the scheduling constraints for when the profile begins.

RecurrenceFrequency

the recurrence frequency. How often the schedule profile should take effect. This value must be Week, meaning each week will have the same set of profiles. For example, to set a daily schedule, set schedule to every day of the week. The frequency property specifies that the schedule is repeated weekly.

Name Type Description
Day
  • string
Hour
  • string
Minute
  • string
Month
  • string
None
  • string
Second
  • string
Week
  • string
Year
  • string

RecurrentSchedule

The scheduling constraints for when the profile begins.

Name Type Description
days
  • string[]

the collection of days that the profile takes effect on. Possible values are Sunday through Saturday.

hours
  • integer[]

A collection of hours that the profile takes effect on. Values supported are 0 to 23 on the 24-hour clock (AM/PM times are not supported).

minutes
  • integer[]

A collection of minutes at which the profile takes effect at.

timeZone
  • string

the timezone for the hours of the profile. Some examples of valid time zones are: Dateline Standard Time, UTC-11, Hawaiian Standard Time, Alaskan Standard Time, Pacific Standard Time (Mexico), Pacific Standard Time, US Mountain Standard Time, Mountain Standard Time (Mexico), Mountain Standard Time, Central America Standard Time, Central Standard Time, Central Standard Time (Mexico), Canada Central Standard Time, SA Pacific Standard Time, Eastern Standard Time, US Eastern Standard Time, Venezuela Standard Time, Paraguay Standard Time, Atlantic Standard Time, Central Brazilian Standard Time, SA Western Standard Time, Pacific SA Standard Time, Newfoundland Standard Time, E. South America Standard Time, Argentina Standard Time, SA Eastern Standard Time, Greenland Standard Time, Montevideo Standard Time, Bahia Standard Time, UTC-02, Mid-Atlantic Standard Time, Azores Standard Time, Cape Verde Standard Time, Morocco Standard Time, UTC, GMT Standard Time, Greenwich Standard Time, W. Europe Standard Time, Central Europe Standard Time, Romance Standard Time, Central European Standard Time, W. Central Africa Standard Time, Namibia Standard Time, Jordan Standard Time, GTB Standard Time, Middle East Standard Time, Egypt Standard Time, Syria Standard Time, E. Europe Standard Time, South Africa Standard Time, FLE Standard Time, Turkey Standard Time, Israel Standard Time, Kaliningrad Standard Time, Libya Standard Time, Arabic Standard Time, Arab Standard Time, Belarus Standard Time, Russian Standard Time, E. Africa Standard Time, Iran Standard Time, Arabian Standard Time, Azerbaijan Standard Time, Russia Time Zone 3, Mauritius Standard Time, Georgian Standard Time, Caucasus Standard Time, Afghanistan Standard Time, West Asia Standard Time, Ekaterinburg Standard Time, Pakistan Standard Time, India Standard Time, Sri Lanka Standard Time, Nepal Standard Time, Central Asia Standard Time, Bangladesh Standard Time, N. Central Asia Standard Time, Myanmar Standard Time, SE Asia Standard Time, North Asia Standard Time, China Standard Time, North Asia East Standard Time, Singapore Standard Time, W. Australia Standard Time, Taipei Standard Time, Ulaanbaatar Standard Time, Tokyo Standard Time, Korea Standard Time, Yakutsk Standard Time, Cen. Australia Standard Time, AUS Central Standard Time, E. Australia Standard Time, AUS Eastern Standard Time, West Pacific Standard Time, Tasmania Standard Time, Magadan Standard Time, Vladivostok Standard Time, Russia Time Zone 10, Central Pacific Standard Time, Russia Time Zone 11, New Zealand Standard Time, UTC+12, Fiji Standard Time, Kamchatka Standard Time, Tonga Standard Time, Samoa Standard Time, Line Islands Standard Time

ScaleAction

The parameters for the scaling action.

Name Type Description
cooldown
  • string

the amount of time to wait since the last scaling action before this action occurs. It must be between 1 week and 1 minute in ISO 8601 format.

direction

the scale direction. Whether the scaling action increases or decreases the number of instances.

type

the type of action that should occur when the scale rule fires.

value
  • string

the number of instances that are involved in the scaling action. This value must be 1 or greater. The default value is 1.

ScaleCapacity

The number of instances that can be used during this profile.

Name Type Description
default
  • string

the number of instances that will be set if metrics are not available for evaluation. The default is only used if the current instance count is lower than the default.

maximum
  • string

the maximum number of instances for the resource. The actual maximum number of instances is limited by the cores that are available in the subscription.

minimum
  • string

the minimum number of instances for the resource.

ScaleDirection

the scale direction. Whether the scaling action increases or decreases the number of instances.

Name Type Description
Decrease
  • string
Increase
  • string
None
  • string

ScaleRule

A rule that provide the triggers and parameters for the scaling action.

Name Type Description
metricTrigger

the trigger that results in a scaling action.

scaleAction

the parameters for the scaling action.

ScaleType

the type of action that should occur when the scale rule fires.

Name Type Description
ChangeCount
  • string
ExactCount
  • string
PercentChangeCount
  • string

TimeAggregationType

time aggregation type. How the data that is collected should be combined over time. The default value is Average.

Name Type Description
Average
  • string
Count
  • string
Last
  • string
Maximum
  • string
Minimum
  • string
Total
  • string

TimeWindow

A specific date-time for the profile.

Name Type Description
end
  • string

the end time for the profile in ISO 8601 format.

start
  • string

the start time for the profile in ISO 8601 format.

timeZone
  • string

the timezone of the start and end times for the profile. Some examples of valid time zones are: Dateline Standard Time, UTC-11, Hawaiian Standard Time, Alaskan Standard Time, Pacific Standard Time (Mexico), Pacific Standard Time, US Mountain Standard Time, Mountain Standard Time (Mexico), Mountain Standard Time, Central America Standard Time, Central Standard Time, Central Standard Time (Mexico), Canada Central Standard Time, SA Pacific Standard Time, Eastern Standard Time, US Eastern Standard Time, Venezuela Standard Time, Paraguay Standard Time, Atlantic Standard Time, Central Brazilian Standard Time, SA Western Standard Time, Pacific SA Standard Time, Newfoundland Standard Time, E. South America Standard Time, Argentina Standard Time, SA Eastern Standard Time, Greenland Standard Time, Montevideo Standard Time, Bahia Standard Time, UTC-02, Mid-Atlantic Standard Time, Azores Standard Time, Cape Verde Standard Time, Morocco Standard Time, UTC, GMT Standard Time, Greenwich Standard Time, W. Europe Standard Time, Central Europe Standard Time, Romance Standard Time, Central European Standard Time, W. Central Africa Standard Time, Namibia Standard Time, Jordan Standard Time, GTB Standard Time, Middle East Standard Time, Egypt Standard Time, Syria Standard Time, E. Europe Standard Time, South Africa Standard Time, FLE Standard Time, Turkey Standard Time, Israel Standard Time, Kaliningrad Standard Time, Libya Standard Time, Arabic Standard Time, Arab Standard Time, Belarus Standard Time, Russian Standard Time, E. Africa Standard Time, Iran Standard Time, Arabian Standard Time, Azerbaijan Standard Time, Russia Time Zone 3, Mauritius Standard Time, Georgian Standard Time, Caucasus Standard Time, Afghanistan Standard Time, West Asia Standard Time, Ekaterinburg Standard Time, Pakistan Standard Time, India Standard Time, Sri Lanka Standard Time, Nepal Standard Time, Central Asia Standard Time, Bangladesh Standard Time, N. Central Asia Standard Time, Myanmar Standard Time, SE Asia Standard Time, North Asia Standard Time, China Standard Time, North Asia East Standard Time, Singapore Standard Time, W. Australia Standard Time, Taipei Standard Time, Ulaanbaatar Standard Time, Tokyo Standard Time, Korea Standard Time, Yakutsk Standard Time, Cen. Australia Standard Time, AUS Central Standard Time, E. Australia Standard Time, AUS Eastern Standard Time, West Pacific Standard Time, Tasmania Standard Time, Magadan Standard Time, Vladivostok Standard Time, Russia Time Zone 10, Central Pacific Standard Time, Russia Time Zone 11, New Zealand Standard Time, UTC+12, Fiji Standard Time, Kamchatka Standard Time, Tonga Standard Time, Samoa Standard Time, Line Islands Standard Time

WebhookNotification

Webhook notification of an autoscale event.

Name Type Description
properties
  • object

a property bag of settings. This value can be empty.

serviceUri
  • string

the service address to receive the notification.