- 1 Basic deployment
- 2 Command reference
- 2.1 cloudfier app-deploy <application-path>
- 2.2 cloudfier db-deploy <application-path>
- 2.3 cloudfier full-deploy <application-path>
- 2.4 cloudfier info <application-path>
- 2.5 cloudfier undeploy <application-path>
- 2.6 cloudfier run-tests <application-path>
- 2.7 cloudfier init-project <application-path>
- 2.8 cloudfier add-entity <package-name> <class-name>
- 2.9 cloudfier db-snapshot <application-path>
- 2.10 cloudfier generate <platform> <application-path> <output-path>
Once you are done creating a Cloudfier app, deploying it is really easy.
1 – open the shell tab
2 – Enter: “cloudfier full-deploy <path/to/application>” (for instance, “cloudfier full-deploy cloudfier-examples/expenses/”
This both builds the app and provisions the database. If everything goes well, you will be shown two links, one for launching he UI, and another for launching the REST API.
Logging into an application
In applications that support anonymous access, users can sign in as guest (no password required). For those that don’t, users need to sign up first. Note that Cloudfier credentials used in the development environment do not work on Cloudfier applications. See Authentication in Cloudfier apps.
Note that currently path arguments cannot include ‘..’
cloudfier app-deploy <application-path>
Redeploys the application, the existing database is preserved. If you make a change that only affects the behavior of the application but not the shape of the data (the schema), and you want to preserve the existing data, you can issue the app-deploy command.
cloudfier db-deploy <application-path>
Redeploys the database, recreating the schema to reflect the current application definition, after destroying all existing data, and then populating it with the contents of data.json, if defined. If you just want to reset the database (and not redeploy the app), you can issue the db-deploy command.
cloudfier full-deploy <application-path>
Equivalent to executing the app-deploy and db-deploy commands in sequence. This destroys any existing data.
cloudfier info <application-path>
Shows information about a deployed application, including links to the Simple UI/REST API. This operation is read-only.
» cloudfier info cloudfier-examples/expenses deployed = true Start Application User Interface Browse Application REST API (make sure to log in via UI first)
cloudfier undeploy <application-path>
Undeploys an application that is currently deployed.
cloudfier run-tests <application-path>
Runs all tests in the application.
Tests are any classes marked with a [Test] annotation. Any public non-static parameter-less operations in those classes are considered test cases. Test cases that should fail should be annotated with the [Failure] annotation, with the expected failing constraint/context described in the annotation.
You can use the Assert class for assertions.
Note that you need to set the mdd.enableTests property to true and deploy before running tests.
Example: car-rental sample application.
cloudfier init-project <application-path>
Turns a regular folder into a Cloudfier project. Basically lays a mdd.properties file (the project configuration file) into the given directory.
cloudfier add-entity <package-name> <class-name>
Creates a TextUML source file in the current directory with a single class named as requested.
cloudfier db-snapshot <application-path>
Takes a snapshot current database state and generates a data.json file in the current or given directory. Note that this will replace an existing data.json file without warning.
cloudfier generate <platform> <application-path> <output-path>
Generates code for the target platform chosen (currently supported: jee and jse), from the given application and into the given output location (which may not exist yet).