Introduction
After deploying a new deployment package to an environment, the following error is shown in the application logs during startup:
Error: Executing start did not succeed. result: 3, message: The database has to be updatedEnvironment/Prerequisites
Applications hosted in Mendix Cloud
Details
Although this message is logged as an error, it is not a blocking error. It represents the expected behavior that always occurs when deploying a package where the Domain Model differs from the existing database structure.
When changes are made to the domain model, for instance, adding a new attribute to an entity, the database structure must be updated. When an application is started, database synchronization is initiated. This manages changes to the database structure and must be applied when an application is deployed after updating the domain model. For more information, refer to the Runtime Server | Database Synchronization documentation.
In other words, the deployment process identifies the desired database state based on the deployment package (.mda file) and compares it to the current state of the existing database structure. It then determines the necessary changes to transition from one state to another and executes them. It is worth mentioning that this process should not take more than a few seconds, and when completed, the following loglines are shown:
[APP/PROC/WEB/0] OUT INFO - Core: Executing DDL commands...
[APP/PROC/WEB/0] OUT INFO - ConnectionBus: Executing 834 database synchronization command(s)...
[APP/PROC/WEB/0] OUT INFO - ConnectionBus: Executing database synchronization commands finished.
[APP/PROC/WEB/0] OUT INFO - Core: Executed DDL commands.Internal information related
- 222383, 212273
- CLDOPS-14228
Additional information
Mendix documentation: Runtime Server and Database Synchronization
0 Comments