Scale Up or Scale Down a Service Instance

post

/paas/api/v1.1/instancemgmt/{identityDomainId}/services/jaas/instances/{serviceId}/hosts/scale

Scales up or down an Oracle Java Cloud Service instance by changing the compute shape of the nodes.

You can scale hosts that contain the Administration Server node and Managed Server nodes in a WLS application cluster.

You cannot scale nodes in the caching (data grid) cluster.

You can scale Oracle Traffic Director load balancer nodes.

Scaling is not supported by Oracle Java Cloud Service - Virtual Image instances (BASIC service level).

Before scaling up a BYOL instance (service instance that was created with isBYOL set to true), verify that you have the required Oracle WebLogic Server licenses for the additional OCPUs provided by the shape that you intend to specify. For the processor conversion ratios and license requirements, refer to the document titled Oracle PaaS and IaaS Universal Credits Service Descriptions that is available from Frequently Asked Questions: Oracle BYOL to PaaS.

On Oracle Cloud Infrastructure and Oracle Cloud Infrastructure Classic: Many of the administration and lifecycle operations that you run for an Oracle Java Cloud Service instance affect the billing for the infrastructure resources that are used by the instance. See Effect of Lifecycle and Administration Operations on Billing.

Request

Supported Media Types
Path Parameters
Header Parameters
Body ()
The request body defines the details of the operation.
Root Schema : scaleupdown-postrequestm
Type: object
Show Source
  • components
    Groups properties for the Oracle WebLogic Server component (WLS) or the Oracle Traffic Director component (OTD). Only one component type should be scaled at a time.
Nested Schema : components
Type: object
Groups properties for the Oracle WebLogic Server component (WLS) or the Oracle Traffic Director component (OTD). Only one component type should be scaled at a time.
Show Source
Nested Schema : OTD
Type: object
Properties for the Oracle Traffic Director (OTD) component.
Show Source
  • hosts
    Name of the host that contains the secondary or primary node.
  • Desired compute shape for the target host.

    On Oracle Cloud Infrastructure, only VM.Standard and BM.Standard shapes are supported.

    Available shapes vary depending on your Oracle Cloud account and the region in which you provision a service instance.

    See Compute Shapes in the Oracle Cloud Infrastructure documentation.

    On Oracle Cloud Infrastructure Classic, valid shapes include:

    • oc3: 1 OCPU, 7.5 GB memory
    • oc4: 2 OCPUs, 15 GB memory
    • oc5: 4 OCPUs, 30 GB memory
    • oc6: 8 OCPUs, 60 GB memory
    • oc7: 16 OCPUs, 120 GB memory
    • oc8: 24 OCPUs, 180 GB memory
    • oc9: 32 OCPUs, 240 GB memory
    • oc1m: 1 OCPU, 15 GB memory
    • oc2m: 2 OCPUs, 30 GB memory
    • oc3m: 4 OCPUs, 60 GB memory
    • oc4m: 8 OCPUs, 120 GB memory
    • oc5m: 16 OCPUs, 240 GB memory
    • oc8m: 24 OCPUs, 360 GB memory
    • oc9m: 32 OCPUs, 480 GB memory

    Note: Some shapes might not be available in a region.

Nested Schema : WLS
Type: object
Properties for the Oracle WebLogic Server (WLS) component.
Show Source
  • hosts
    A single host name. Only application cluster hosts can be specified.
  • Flag that indicates whether to ignore Managed Server heap validation (true) or perform heap validation (false) before a scale down request is accepted. Default is false.

    When the flag is not set or is false, heap validation is performed before scaling. If a validation error is not generated, the Managed Server JVM is restarted with the new shape after scaling down.

    When the flag is true, heap validation is not performed. Before you set the flag to true, make sure the -Xms value is low enough for the Managed Server JVM to restart on the new shape after scaling down. The -Xms value should be lower than one-fourth the size of the memory associated with the shape. Use the WebLogic Server Administration Console to edit the value in the server start arguments, if necessary.

  • Desired compute shape for the target host.

    On Oracle Cloud Infrastructure, only VM.Standard and BM.Standard shapes are supported.

    Available shapes vary depending on your Oracle Cloud account and the region in which you provision a service instance.

    See Compute Shapes in the Oracle Cloud Infrastructure documentation.

    On Oracle Cloud Infrastructure Classic, valid shapes include:

    • oc3: 1 OCPU, 7.5 GB memory
    • oc4: 2 OCPUs, 15 GB memory
    • oc5: 4 OCPUs, 30 GB memory
    • oc6: 8 OCPUs, 60 GB memory
    • oc7: 16 OCPUs, 120 GB memory
    • oc8: 24 OCPUs, 180 GB memory
    • oc9: 32 OCPUs, 240 GB memory
    • oc1m: 1 OCPU, 15 GB memory
    • oc2m: 2 OCPUs, 30 GB memory
    • oc3m: 4 OCPUs, 60 GB memory
    • oc4m: 8 OCPUs, 120 GB memory
    • oc5m: 16 OCPUs, 240 GB memory
    • oc8m: 24 OCPUs, 360 GB memory
    • oc9m: 32 OCPUs, 480 GB memory

    Note: Some shapes might not be available in a region.

Nested Schema : hosts
Type: array
Name of the host that contains the secondary or primary node.
Show Source
Nested Schema : hosts
Type: array
A single host name. Only application cluster hosts can be specified.
Show Source
Back to Top

Response

Supported Media Types

202 Response

Accepted. The Location header returns a URI that can be used to view the job status. See View the Status of an Operation by Job Id.
Body ()
Root Schema : accepted-responsem
Type: object
The response body contains information about the operation. It can include an issues array for warning messages.
Show Source
Nested Schema : details
Type: object
Groups details of the operation.
Show Source
Nested Schema : issues
Type: array
Groups strings of warning messages, if any.
Show Source

400 Response

Bad Request. Returned if the request payload contains bad or missing details.

See Status Codes for information about other possible HTTP status codes.

Body ()
Root Schema : badrequest-responsem
Type: object
The response body contains information about the request. It can include an issues array for validation error messages.
Show Source
Nested Schema : details
Type: object
Groups details of the request.
Show Source
Nested Schema : issues
Type: array
Groups strings of validation error messages, if any.
Show Source
Back to Top

Examples

The following example shows how to scale up or scale down an Oracle Java Cloud Service instance by submitting a POST request on the REST resource using cURL.

Note: The command in this example uses the URL structure https://rest_server_url/resource-path, where rest_server_url is the REST server to contact for your identity domain (or Cloud Account). See Send Requests.

cURL Command

curl -i -X POST -u username:password -d @scaleup.json -H "Content-Type:application/json" -H "X-ID-TENANT-NAME:ExampleIdentityDomain" https://rest_server_url/paas/api/v1.1/instancemgmt/ExampleIdentityDomain/services/jaas/instances/ExampleInstance/hosts/scale

Example of Request Body

The following shows an example of the request body for scaling up a host.

{
   "components": {
      "WLS": {
         "hosts": ["exampleinstance-wls-2"],
         "shape": "oc5",
         "ignoreManagedServerHeapError": true
      }
   }
} 

Example of Response Header

The following shows an example of the response header. The Location header returns the URI that can be used to view the job status. See View the Status of an Operation by Job Id.

HTTP/1.1 202 Accepted
Date: Tue, 23 May 2017 18:37:36 GMT
Location: https://rest_server_url/paas/api/v1.1/activitylog/ExampleIdentityDomain/job/24048717
Content-Type: application/json

Example of Response Body

The following shows an example of a 202 response returned in JSON format.

{
   "details":{
      "message":"Submitted job to scaling job in service [ExampleInstance] in domain [ExampleIdentityDomain].",
      "jobId":"24048717"
   }
}

The following shows an example of a 400 response.

{
    "details": {
        "message": "PSM-LCM-00012 The node [example2instance-wls-2] doesn't exist in component [WLS] for service [ExampleInstance].  You can only specify host names that are provisioned using the component parameter hosts."
    }
}

The following shows an example of a 400 response that includes the issues array.

{
    "details": {
        "message": "Unable to submit the scaling request.  Check additional validation errors for details.",
        "issues": [
            "[Value for parameter shape [oc33] is not a valid shape for the service]"
        ]
    }
}
Back to Top