Changes the instance type of an application.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request headers

This operation uses only common request headers and does not have operation-specific request headers. For more information, see Common request and response headers.

Request syntax

POST /pop/v1/sam/app/rescaleApplicationVertically HTTP/1.1

Request parameters

ParameterTypePositionRequiredExampleDescription
AppIdStringQueryYes0099b7be-5f5b-4512-a7fc-56049ef1****

The application ID.

CpuStringQueryYes1000

The new CPU specification. Unit: millicore.

MemoryStringQueryYes2048

The new memory size. Unit: MB.

Response parameters

ParameterTypeExampleDescription
RequestIdStringAB521DBB-FA78-42E6-803F-A862EA4F****

The request ID.

MessageStringsuccess

The returned message.

TraceIdString0bc3b6f315637273629117900d****

The trace ID that is used to query the details of the request.

DataObject

The returned result.

ChangeOrderIdStringffd8cd45-2b5f-415d-b4d0-1003e80b****

The ID of the change order.

ErrorCodeStringNull

The error code. Valid values:

  • If the call is successful, the ErrorCode parameter is not returned.
  • If the call fails, the ErrorCode parameter is returned. For more information, see the "Error codes" section in this topic.
CodeString200

The HTTP status code. Valid values:

  • 2xx: The call was successful.
  • 3xx: The call was redirected.
  • 4xx: The call failed.
  • 5xx: A server error occurred.
SuccessBooleantrue

Indicates whether the instance type was changed. Valid values:

  • true: The instance type was changed.
  • false: The instance type failed to be changed.

Examples

Sample requests

POST /pop/v1/sam/app/rescaleApplicationVertically?AppId=0099b7be-5f5b-4512-a7fc-56049ef1****&Cpu=1000&Memory=2048 HTTP/1.1
Host:sae.aliyuncs.com
Content-Type:application/json

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<RescaleApplicationVerticallyResponse>
    <RequestId>AB521DBB-FA78-42E6-803F-A862EA4F****</RequestId>
    <Message>success</Message>
    <TraceId>0bc3b6f315637273629117900d****</TraceId>
    <Data>
        <ChangeOrderId>ffd8cd45-2b5f-415d-b4d0-1003e80b****</ChangeOrderId>
    </Data>
    <Code>200</Code>
    <Success>true</Success>
</RescaleApplicationVerticallyResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "AB521DBB-FA78-42E6-803F-A862EA4F****",
  "Message" : "success",
  "TraceId" : "0bc3b6f315637273629117900d****",
  "Data" : {
    "ChangeOrderId" : "ffd8cd45-2b5f-415d-b4d0-1003e80b****"
  },
  "Code" : "200",
  "Success" : true
}

Error codes

HTTP status codeError codeError messageDescription
400InvalidApplication.NotFoundThe current application does not exist.The specified application is not found.
400InvalidInstanceSpecification.UnsupportedThe instance specification is not supported: CPU [%s], memory [%s].The following instance type is not supported: CPU [%s], memory [%s].
400InvalidParameter.NotEmptyYou must specify the parameter %s.The value of the %s parameter is invalid. This parameter cannot be left empty.
400InvalidParameter.ObviouslyThe specified parameter is invalid {%s}.The value of the {%s} parameter is invalid.
400InvalidParameter.WithMessageThe parameter is invalid {%s}: %sThe value %s of the {%s} parameter is invalid.
400user.indebtThe user has an outstanding payment.The current user has overdue payments.
400System.UpgradingThe system is being upgraded. Please try again later.The system is being upgraded. Try again later.
400Application.ChangerOrderRunningAn application change process is in progress. Please try again later.An application change is in progress. Try again later.
400Application.InvalidStatusThe application status is abnormal. Please try again later.The application is in an abnormal state. Try again later.
400Application.NotDeployYetThe application has not been deployed. Please deploy it and try again.The application is not deployed. Deploy the application and try again.

For a list of error codes, see Service error codes.