Licensing Mendix Cloud Apps
Introduction
You can only run a Mendix app in production on Mendix Cloud if the app is linked to a licensed node.
Without a licensed node, you can still deploy your app and test it, but it will have several limitations:
- It runs for only a couple of hours before shutting down
- It cannot be scaled
- It has limited operational information available
This page explains how to link your app to a licensed node. It covers the following topics:
Basic Concepts and Overview
When you deploy an app to the cloud, whether it is a Free App or a licensed app, it consists of several parts:
- Mendix Runtime – essentially, one or more instances of your app running in a container
- Routing layer
- Network
- Database
- File storage service
This is the Mendix environment.
In a node in Mendix Cloud, you may have one or more of these environments.
For a Free App, your app has a single environment where you can test your app. However, it comes with restrictions on how long it will run. In addition, you cannot scale the app, and the operational capabilities are limited. For details on the restrictions of a Free App, see Mendix Cloud.
In a licensed node, you have everything you need to stage and deploy your app. You can have several different environments to support development; for example, you can have test, acceptance, and production environments. With Flexible Environments in Mendix Cloud, you can even specify the number and names of your environments. You can scale licensed environments by providing more memory or multiple instances, and you can configure and monitor them using the tools in the Mendix Portal.
Prerequisites
Obtaining a Licensed Node
To license an app, you must have a licensed cloud node available:
If you want to license a single app for between five and one hundred users, you can order the Mendix Basic package online. For more information, see Mendix Basic Package.
If you have an existing contract that allows for more licensed nodes, use the Request New App Node app to request a new node from Mendix Support. For more information, see Licensing Apps.
If none of the categories above apply to your case, contact Mendix Support.
Authorization
To link an app to a licensed node, you need to be the Technical Contact of the node.
You also need to have enabled two-factor authentication. For more information, see Two-Factor Authentication.
Linking Your App to a Licensed Node
Consider the following case: You have deployed an app, either as a Free App or to a licensed node. You now want to link it to a licensed node (or move it from one licensed node to another licensed node). To link the app to the node, carry out the following steps:
Backing Up
When you remove an app from its environment, you may want to take the data (database and file store) with it. It is a good idea, in any case, to create backups before performing major activities.
For more details on downloading a backup, see Download a Backup.
If you unlink an app from a licensed node, that does not delete the node. Data is retained in the node.
Unlinking From Current Environment
It is not necessary to unlink an app from its current environment before linking it to a new node. Instead, you can connect another app to the node; this automatically unlinks the existing app.
The Exchanging Linked Apps Between Nodes section provides an example of how you can use this behavior.
Connecting Your App to a Licensed Node
Apart from the app, the rest of the environment (or environments) in the target node will remain the same. This includes the following:
- The container and its configuration (including memory, instances, and environment variables)
- Routing layer
- Network
- Database (both structure and content)
- File storage service (including all content)
To connect your app to a licensed node, do the following:
-
From Apps, go to the Environments page of the app you want to unlink.
-
Click Select Licensed Node.
-
If prompted, authenticate yourself with two-factor authentication.
-
In the list of your cloud nodes, click Use this Node by the node that you want to connect to your app.
-
If there is already an app linked to the node, you will be prompted to confirm that you want to replace it. Click Proceed to confirm.
Unlinking a sandbox app cannot be undone. All data in the app is deleted. Before you proceed, make sure to download a backup of the app that you want to replace.
Linking a new project to a node removes all existing team members and resets node permissions. The technical contact must re-add everyone to the project, and reconfigure any necessary settings.
Your app is now connected to this node.
Restoring Backup
After you link your app to a licensed node, it uses the resources in that node. For example, if there was an app previously deployed to the node, your newly linked app uses the data in the existing database.
If you want to use the data that was originally in your app, you need to restore the backup from your old node. For details on how to restore a backup, see Restore a Backup.
Exchanging Linked Apps Between Nodes
If you want to swap the nodes of two apps that are already linked to nodes, create a new (third) app. Linking an app to a node removes the app that is already linked, so you can use your third app to unlink one of the apps. You can then move your unlinked app to the other node, unlinking the app that is there. Finally, you can link that app to the first node.
For example, take the following case:
-
App A is on Node 1
-
App B is on Node 2
-
You want to swap them so that App A is on Node 2 and App B is on Node 1
To link App A to Node 2 and App B to Node 1, follow these steps:
-
Create a new, blank app App C. Do not connect it to any environment.
-
Link App C to Node 1 (see the Connecting Your App to a Licensed Node section, above). This unlinks App A.
-
Now that App A is unlinked from Node 1, you can link it to Node 2.
-
App B no longer has a node. So, you can link App B to Node 1.
You have now swapped App A and App B between nodes.