---
schema_version: "1"
id: a76d66346b923ea9c106f583a44c9f7de806ea09fa378ba53f51b9a8a7357a26
title: Autoscaling in CloudHub
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/cloudhub/autoscaling-in-cloudhub.md
canonical_url: https://docs.mulesoft.com/cloudhub/autoscaling-in-cloudhub
source_site: docs.mulesoft.com
content_type: documentation
content_hash: d8b868c9793f32fe2f740a1a294a002fb1c0d9805e3669a7836d4c40f96b921c
description: MuleSoft Documentation Site
latest: true
---
---
product: CloudHub
---

# Autoscaling in CloudHub

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

> [!NOTE] To use the autoscaling feature, your organization must have an Enterprise License
> Agreement (ELA). Entitlement is approved based on qualified use cases. If you are interested in
> this feature, contact your account representative.
>
> Autoscaling isn’t available on CloudHub for Usage-based Pricing (UBP) organizations.

CloudHub allows you to make the processing power behind your applications responsive to changes in
their usage. You can define policies that respond to CPU or memory usage thresholds by scaling up or
scaling down the processing resources used by an application.

## Configure Autoscaling

1.  Click the **Applications** tab of Runtime Manager.

2.  Select an application deployed to CloudHub to open its panel.

3.  In the panel, click **Manage Application**.

4.  In the **Settings** section, select the **Autoscaling** tab.  
    You can see all existing autoscaling policies, activate or deactivate them, create or delete
    them, and create associated
    [Alerts on Runtime Manager](https://docs.mulesoft.com/runtime-manager/alerts-on-runtime-manager).

## Create a Policy

To create a policy, click the **Create Policy** button, then configure the fields to set your policy
up.

![policy](/mulesoft/current/en-us/cloudhub/_images/autoscale-create-policy.png)

Changes in worker size or number are triggered when a policy meets its requirements. Policies can be
based either upon CPU or Memory usage, and they can either modify worker numbers or worker size. All
policies include a scale up and a scale down condition.

![form](/mulesoft/current/en-us/cloudhub/_images/policy-form.png)

1.  Provide a **Name** for your policy.

2.  Determine if the scaling will be based on **Memory or CPU usage**.

    > [!NOTE]
    >
    > - For **CPU**: The percentage shown is the worker’s total CPU usage relative to its allocated
    >   CPU capacity. Autoscaling is triggered based on the worker’s overall CPU usage, not JVM CPU
    >   usage alone.
    >
    > - For **Memory**: The percentage shown is the percentage of total memory allocated for the JVM
    >   that’s being used, including memory consumed by the JVM itself.

3.  Determine the **Rules** for your scaling. You must provide the following values for both the
    upscale and the downscale conditions:

    1.  A usage **percentage**

    2.  A period of **time** throughout which this level must be sustained before the policy is
        applied

    3.  A **cool-down period** that blocks this and other policies from affecting scaling from being
        applied

4.  Define what **action** will be performed when the policy is applied:

    1.  If it will affect the **number** of workers or the **size** of them

    2.  Set a **maximum** and **minimum** value to fluctuate in between

> [!NOTE] Maximum number of workers is 4, and maximum worker size is 16 vCores for the Autoscaling
> policy.

## Scaling Considerations

All policies scale your application one step at a time. To scale up to meet a pronounced spike that
requires scaling numerous steps, each step takes CloudHub the sum of the policy evaluation time plus
the cool-down period.

You can apply only one autoscaling policy per application.

The maximum amount and size of workers that you have available is limited by the characteristics of
your account. If multiple applications running in your account compete for limited resources, they
are allocated in a first-come, first-served manner.

Autoscaling fails if your org reaches its vCore limit because there are no available resources to
provision new workers. To continue, increase your org’s vCore limit or stop unused apps to free up
vCores.

## Edit an Existing Policy

To edit an existing policy, open the **Policies** tab. Click the policy name and you will access the
same menu that is used to create a new policy.

## Deactivate a Policy

To deactivate a running policy, open the policies tab and flip the switch in its corresponding
**Status** field:

![enable](/mulesoft/current/en-us/cloudhub/_images/enable-policy.png)

## Delete a Policy

To delete an existing policy, go to the policies tab, then click its corresponding delete icon.

## Set an Alert and View Autoscaling History

Two specific types of Alerts can be set up for applications on CloudHub that warn you whenever a
worker autoscaling event occurs. One alerts you about scale ups and the other about scale downs.

With this alert set, emails will be automatically sent to the addresses you provide whenever such an
event occurs.

You can also see a full history of all of the times that the alert has been triggered. To see this,
from the **Alerts** page, click on an alert name to open its corresponding panel:

![history](/mulesoft/current/en-us/cloudhub/_images/alerts-history-autoscale.png)

## See Also

- [Alerts on Runtime Manager](https://docs.mulesoft.com/runtime-manager/alerts-on-runtime-manager)

- [Manage Deployed Applications](https://docs.mulesoft.com/runtime-manager/managing-deployed-applications)

- [CloudHub](https://docs.mulesoft.com/cloudhub/)

- [Deployment Options](https://docs.mulesoft.com/runtime-manager/deployment-strategies)

- [Clustering](https://docs.mulesoft.com/cloudhub/cloudhub-fabric)

- [Anypoint Platform Command-Line Interface](https://docs.mulesoft.com/anypoint-cli/latest/)

- [Secure Application Properties](https://docs.mulesoft.com/cloudhub/secure-application-properties)

- [Virtual Private Cloud](https://docs.mulesoft.com/cloudhub/virtual-private-cloud)
