🚀 Welcome to MDriven Learn –  MDriven is now on Discord!  Don’t miss the latest Release Notes.
Bootcamp: Chapter 15 – Upload the Model to MDrivenServer
This page was created by Wikiadmin on 2026-07-29. Last edited by Wikiadmin on 2026-07-29.

You can upload a MDriven Designer model to MDrivenServer and verify how the server updates the relational database schema; this Bootcamp chapter is for developers running their application with MDrivenServer persistence.

Chapter 14 established a local MDrivenServer connection and migrated data. In this chapter, you change the model and observe how MDrivenServer keeps its database schema aligned with it.

Before you begin

Make sure that:

  • Your model is connected to an active MDrivenServer.
  • MDrivenServer is running.
  • You have uploaded the current model at least once.
  • The active server is selected in the cloud-connection dialog.

MDrivenServer receives the model from MDriven Designer and creates or evolves the database used to store model data. See MDrivenServer Summarized for an overview.

Upload the model

  1. In MDriven Designer, add a new class named Class1.
  2. Open the cloud-connection dialog from the toolbar.
  3. Click Upload Model. This sends the current model to the active MDrivenServer.
  4. Click Check Server Status.
  5. If the status does not show new feedback, wait one second and click Check Server Status again.
  6. Verify that the status reports that a table for storing Class1 objects was added to the database.

The server maps a model class to database storage. For example, creating Class1 causes MDrivenServer to create storage for instances of that class.

Verify schema changes

A database schema is the definition of database tables and columns. When you change classes, attributes, or associations in a model that uses MDrivenServer persistence, upload the model so that the server can update the schema.

Add attributes

  1. Add several attributes to Class1.
  2. Click Upload Model.
  3. Click Check Server Status.
  4. Verify that the status states that the database schema changed to accommodate the new attributes.

For example, if you add a Name attribute to Class1, MDrivenServer adds storage for that attribute.

Remove attributes

  1. Delete one or more attributes from Class1.
  2. Click Upload Model.
  3. Click Check Server Status.
  4. Verify that the status reports that columns were removed from the Class1 table.

Deleting an attribute from the model removes its corresponding database column when the updated model is uploaded.

Add an association

An association is a relationship between two classes. At the database level, MDrivenServer stores an association by using a foreign-key column. A foreign key holds the primary key of the related object.

  1. Add an association between Class1 and BrandOfCar.
  2. Click Upload Model.
  3. Click Check Server Status.
  4. Verify that the status reports that MDrivenServer added a column to store the association foreign key.

For example, the new column in the BrandOfCar or Class1 table stores the identity of the object at the other end of the association.

Remove the experimental class

  1. Delete Class1 from the model.
  2. Click Upload Model.
  3. Click Check Server Status.
  4. Verify that the status reports that MDrivenServer dropped the table for Class1 and removed the foreign-key column created for its association with BrandOfCar.

Check the uploaded model in MDrivenServer

You can inspect the model that MDrivenServer received in its web user interface.

  1. Open the MDrivenServer address in a browser. For the local Bootcamp server, use http://localhost:5000.
  2. Sign in with the server credentials. The local Bootcamp example uses user a and password 123456.
  3. Select Running, then select Model.
  4. Verify that the uploaded model is displayed.

For local development, the example credentials are only appropriate when the server is reachable only from your machine. Do not use weak credentials on a server exposed to other users or the internet.

What to do after model changes

Upload the model whenever you make a model change that must be used by MDrivenServer or its database. For example, after adding a ViewModel action and changing its behavior, save the model, click Upload Model, and then test the application against the updated server model.

When you deploy for other users, run MDrivenServer and MDriven Turnkey on a server that they can reach, such as an internal company network or an internet-hosted server.

See also