SALES: 1-800-867-1380

Get Autoscale Settings

Updated: April 15, 2015

The Get Autoscale Settings operation can be used to retrieve automatic scaling settings from deployments of Cloud Services, Virtual Machines, Websites, and Mobile Services.

The Get Autoscale Settings request may be specified as follows. Replace <subscription-id> with the subscription ID.

 

Method Request URI

GET

https://management.core.windows.net/<subscription-id>/services/monitoring/autoscalesettings

You must make sure that the request that is made to the management service is secure. For additional details, see Authenticating Service Management Requests.

The following table lists the parameter to use for a cloud service that has web roles or worker roles deployed to it. Replace <cloudservice> with the name of the cloud service, <deployment-slot> with staging or production, and <role> with the name of the role. The parameter is case-sensitive.

 

URI Parameter Description

resourceId=/hostedservices/<cloudservice>/deploymentslots/<deployment-slot>/roles/<role>

Required. Specifies that the automatic scaling settings should be retrieved from roles in the production or staging deployment environments for the specified cloud service. For more information about finding the names of cloud services in your subscription, see List Cloud Services.

The following table lists the parameter to use for a cloud service that has Virtual Machines deployed to it. Replace <cloudservice> with the name of the cloud service and <availability-set> with the name of the availability set in which the Virtual Machines are a member.

 

URI Parameter Description

resourceId=/virtualmachines/<cloudservice>/availabilitySets/<availability-set>

Required. Specifies that the automatic scaling settings should be retrieved from an availability set of Virtual Machines. For more information about finding the name of an availability set in which a Virtual Machine is a member, see Get Deployment.

The following table lists the parameter to use for Websites. Replace <webspace> with the name of the webspace and <serverfarm> with the name of the server farm in that webspace.

 

URI Parameter Description

resourceId=/webspaces/<webspace>/serverFarms/<serverfarm>

Required. Specifies that the automatic scaling settings should be retrieved from a server farm in a webspace. For more information about finding the names of webspaces, see List Webspaces. For more information about finding the names of server farms, see Create, Manage, or Delete a Server Farm.

The following table lists the parameter to use for Mobile Services. Replace <mobileservice> with the name of the Mobile Service.

 

URI Parameter Description

resourceId=/mobileservices/<mobileservice>/

Required. Specifies that the automatic scaling settings should be retrieved from a Mobile Service.

The following table describes the request headers.

 

Request Header Description

x-ms-version

Required. Specifies the version of the operation to use for this request. This header should be set to 2013-10-01 or higher. For more information about versioning headers, see Service Management Versioning.

The response includes an HTTP status code, a set of response headers, and a response body.

A successful operation returns status code 200 (OK). For information about status codes, see Service Management Status and Error Codes.

The response for this operation includes the following headers. The response may also include additional standard HTTP headers. All standard headers conform to the HTTP/1.1 protocol specification.

 

Response Header Description

x-ms-request-id

A value that uniquely identifies a request made against the management service.

The format of the response body is as follows:


{
  "Profiles": [
    {
      "Name": "name-of-profile",
      "Capacity": {
        "Minimum": "<minimum-number-of-instances>",
        "Maximum": "<maximum-number-of-instances>",
        "Default": "<default-number-of-instances>"
      },
      "Rules": [
        {
          "MetricTrigger": {
            "MetricName": "<name-of-trigger>",
            "MetricNamespace": "<identifier-of-namespace>",
            "MetricSource": "<deployment-resource>",
            "TimeGrain": "<data-collection-time>",
            "Statistic": "<evaluation-of-instances>",
            "TimeWindow": "<range-of-data-collection>",
            "TimeAggregation": "<aggregation-of-data>",
            "Operator": "<data-collection-operator>",
            "Threshold": <usage-amount>
          },
          "ScaleAction": {
            "Direction": "<direction-of-action>",
            "Type": "<type-of-action>",
            "Value": "<size-of-action>",
            "Cooldown": "<time-of-action>"
          },
        },  
      ],
      "Recurrence": {
        "Frequency": "<frequency-of-action>",
        "Schedule": {
          "TimeZone": "<time-zone>",
          "Days": [<days-of-the-week>],
          "Hours": [<number-of-hours>],
          "Minutes": [<number-of-minutes>]
        }
      }
      "FixedDate": {
        "Start": "<start-time-of-action>",
        "End": "<end-time-of-action>",
        "TimeZone": "<time-zone>"
      }
    }
  ],
  "Enabled": <enable-scaling>
}

The following table describes the elements of the response body.

 

Element name Description

Profiles

Contains a collection of automatic scaling profiles that specify different scaling parameters for different time periods.

Enabled

Specifies whether automatic scaling is enabled for the specified role.

Possible values are:

  • true

  • false

Contains a collection of automatic scaling profiles that specify different scaling parameters for different time periods.

 

Element name Description

Name

Specifies the name of the profile.

Capacity

Specifies the number of instances that can be used in the scaling action.

Rules

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

Recurrence

Specifies the frequency and schedule for the scaling action. This element is not used if the FixedDate element is used.

FixedDate

Optional. Specifies a specific date for the scaling action. This element is not used if the Recurrence element is used.

Specifies the number of instances that can be used in the scaling action.

 

Element name Description

Minimum

Specifies the minimum number of instances that are available for the scaling action.

Maximum

Specifies the maximum number of instances that are available for the scaling action. The maximum number of instances is limited by the cores that are available in the subscription. You can use the Management Portal to see the number of cores that are available in your subscription.

Default

Specifies the default number of instances that are available for the scaling action.

Contains a collection of rules that provide the triggers and parameters for the scaling action.

 

Element name Description

MetricTrigger

Specifies the metrics that are used to determine when a scaling action occurs.

ScaleAction

Specifies parameters for the scaling action.

Specifies the metrics that are used to determine when a scaling action occurs.

 

Element name Description

MetricName

Specifies the name of the trigger.

MetricNamespace

Specifies a namespace identifier for the service in which the deployment is running. You can use the Microsoft.WindowsAzure.Management.Monitoring.Metrics APIs to obtain the available metric namespace identifiers.

MetricSource

Specifies the path to the resource to use for scaling by metrics.

The following format is used to define the resource path for cloud services:

/CloudService/<cloud-service>/<deployment-slot>/<role>

The following format is used to define the resource path for scaling by the depth of a queue:

/Storage/<storage-account>/Queue/<queue>

The following format is used to define the resource path for scaling by metrics that are available in the Management Portal for storage accounts:

/Storage/ServiceMetric/<storage-account>/<storage-service>

The following format is used to define the resource path for scaling by the return value of an API:

/Storage/APIMetric/<storage-account>/<storage-service>/<api>

The following format is used to define the resource path for deployments of Service Bus:

/ServiceBus/<servicebus-namespace>/<resource-type>/<entity>

The following format is used to define the resource path for deployments of Virtual Machines:

/VirtualMachinesAvailabilitySet/<cloud-service>/<availability-set>

The following format is used to define the resource path for a server that is running a website:

/WebsiteDedicated/<webspace>/DefaultServerFarm

The following format is used to define the resource path for a logical web application:

/Website/<webspace>/<website>

The following format is used to define the resource path for deployments of Mobile Services:

/MobileService/<mobile-service>

TimeGrain

Specifies the frequency of data collection. Typically, this is set to 5 minutes (PT5M).

Statistic

Specifies how the metrics from multiple instances are combined.

Possible values are:

  • Average

  • Min

  • Max

TimeWindow

Specifies the range of time in which instance data is collected.

The default value is PT45M.

TimeAggregation

Specifies how the data that is collected should be combined over time.

Possible values are:

  • Average

  • Minimum

  • Maximum

  • Last

  • Total

  • Count

The default value is Average.

Operator

Specifies the operator that is used to evaluate the metric.

Possible values are:

  • Equals

  • NotEquals

  • GreaterThan

  • GreaterThanOrEqual

  • LessThan

  • LessThanOrEqual

Threshold

Specifies the percentage of usage that triggers the scaling operation.

Specifies parameters for the scaling action.

 

Element name Description

Direction

Specified whether the scaling action increases or decreases the number of instances that are used.

Possible values are:

  • Increase

  • Decrease

A default profile has 2 rules, one for increasing instances and one for decreasing instances.

Type

Specifies the type of action that should occur.

Currently, this must be set to ChangeCount.

Value

Specifies the number of instances that are involved in the scaling action.

The default size is 1.

Cooldown

Specifies the number of minutes to wait between the last scaling action and the next scale action.

The default value is PT20M.

Specifies the frequency and schedule for the scaling action.

 

Element name Description

Frequency

Required. Specifies how often the scaling action should occur. This value must be Week.

Schedule

Specifies the scheduling constraints of the scaling action.

Specifies a specific date for the scaling action.

 

Element name Description

TimeZone

Required. Specifies the time zone for the scaling action.

Start

Required. Specifies the start time of the scaling action.

End

Required. Specifies the end time of the scaling action.

Specifies the scheduling constraints of the scaling action.

 

Element name Description

TimeZone

Specifies the time zone for the schedule parameters.

Days

Specifies a comma separated list of the days of in schedule.

Possible values are:

  • Monday

  • Tuesday

  • Wednesday

  • Thursday

  • Friday

  • Saturday

  • Sunday

Hours

Specifies the hours when the schedule should run.

Minutes

Specifies the minutes of the hour when the schedule should run. Only one value is supported for this element. You can only schedule an action for once per hour.

You can also use the Management Portal to retrieve autoscale setting for your application. For more information, see How to Scale an Application.

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2015 Microsoft