Is there a way to determine if a data model is the same in different environments?

If I want to deploy to different environments (i.e. testing, staging, production), how can I ensure the data model for each environment? For instance, how do I know what will be deployed if I've adjusted the data model in testing for developing but don't want to change the data model for production?

Is this for a scenario where you want to deploy some code change to production (e.g. a bugfix) but you don’t want to deploy your data model changes in development along with the bugfix?

Yes, or vice versa. For instance, if I want to test a new model for a feature and only test it in the testing environment. But, I don’t want to push that model to Production. It seems I would have to manually delete the model in testing before I could deploy to production. It would be nice to specify data models for environments if possible? @KobieBotha

Gotcha. The right tool for the job here would be to use our GitHub integration, which offers full branching capabilities. You could then keep your testing/dev changes on a develop branch for example. and only deploy master to production. Then you could make sure to pull in all your production bufix changes on master into develop. This is just an example of a branching model you could use.Does that sound like what you’re looking for here?

Yes that does make sense. We don’t currently use GitHub integration. I’m curious if this could be an issue for others who aren’t using GitHub integration either or if a different software like GitLabs, etc. is used. @KobieBotha

We’ve implemented our Git support in an extensible way, so it won’t be too hard to add support for additional providers such as GitLab. Also coming soon is Journey hosted git where you don’t need an external provider. Out of curiosity are you using GitHub or something else?

There is a data model hash associated with each revision or branch of an application. ![The data model hash is in the center of this image](upload://yo1Lc3y30SH33GgbTeURlHSEtTx.png)

Each time you deploy to a new environment, a revision is automatically created, which will show what the deployed data model looks like.

If you want, you can also compare revisions as described Here. By comparing the previous production deploy to the current revision, you can do a quick check to see if the DM is the same.

Another method for determining the data model is by using the back-end API. You can retrieve a JSON or xml version of the data model for a given deployment environment as described here.

There is no way to partially deploy app code, however. If you want to make a deploy to the production environment and exclude changes to the data model, you will need to remove them manually or revert to the previous production version and make changes there. This process of deploying a "hot fix" is made easier if using github integration.