Scaling Your Environment in Mendix Cloud

Last modified: February 19, 2024

1 Introduction

This document explains how to scale an environment in Mendix Cloud. This can take the form of vertical or horizontal scaling:

  • Vertical scaling – You can add memory to the application container.
  • Horizontal scaling – You can configure apps built using supported versions of Mendix to be run in multiple runtime containers (instances) simultaneously. Incoming traffic for your app is distributed over the running instances.

2 Prerequisites

Before following the steps outlined on this page, make sure you meet the following prerequisites:

  • Have a licensed app hosted in Mendix Cloud.
  • Have a standard or premium plan with a cloud resource pack that provides more than 1 GiB of memory. You can find this information on the Environment Details page. For details on the cloud resource packs that Mendix offers, see Cloud Resource Packs.
  • Have Transport Rights for the environment you want to scale. For details on configuring permissions, see Node Permissions.

3 Scaling Your Environment

To scale your licensed app in Mendix Cloud, follow these steps:

  1. From the Developer Portal, go to the Environments page of your licensed app.

  2. Click Details ( ) on the environment you want to scale.

  3. On the General tab, scroll down to the Instances row. Click Change scaling.

  4. To set the Memory per instance that you want to use, drag the Memory per instance indicator bar.

  5. To set the number of Instances you want to use, drag the Instances indicator bar.

  6. Click Apply. This restarts your environment to apply the changes.

    Scaling dashboard

3.1 Scaling Notes

  • Restarting your environment to apply horizontal or vertical scaling changes causes brief downtime.
  • The number of available instances depends on the total memory provided by your cloud resource pack and the memory per instance that you have set. It is not possible to set scaling values that exceed the memory provided by your cloud resource pack.
  • It is not possible for a single instance to use more than 32 GiB of RAM. Some very large cloud resource packs, such as XXXL21 or XXXXL21, provide more than this 32 GiB maximum; to use the full RAM in this case, you need more than one instance. For example, to use 64 GiB of RAM, you must spread the RAM between two or more instances.

4 Examples

The following examples assume that you have 8 GiB memory available in your cloud resource pack.

4.1 Scaling Example 1

You can spread the 8 GiB RAM across 4 instances. For example, you can create 4 instances, each with 2 GiB memory (4 x 2 GiB = 8 GiB).

4.2 Scaling Example 2

You do not need to allocate all the available memory at once. You can just allocate part of it and then use the rest of the memory later by allocating more memory per instance or creating more instances.

For example, you can use one instance with 2 GiB RAM. The remaining 6 GiB in your cloud resource pack will be unused.

Scaling dashboard with 2 out of 8 GB of total allocated memory used

5 Read More