Skip to content

Deploying the Generated Service

Before you can deploy a service, you must generate it. See Generating an OData Service.

After generation, the Java EE WAR file should be found in your project's target subfolder.


You may use the software solely for the purpose of developing applications for use with 'SAP Mobile Services'; provided that for those SDK components that can be used in connection with or deployed on platforms other than SAP Mobile Services, you may use those components other than with SAP Mobile Services if you have obtained a production license to SAP Mobile Services. For more details, please refer to SAP Mobile Services License.

Automated Deployment During Service Generation

See the -cf:push and -local:deploy options.

See the example tasks.json for automated deployment when using SAP Business Application Studio or Visual Studio Code.

Manual Deployment to a Local or On-Premise Web Application Server

The procedure for deployment of the generated Java EE WAR file depends on the target server environment. Consult the relevant documentation for the target server environment for full details.

A number of web application servers may make hot redeployment difficult (without restarting the server and manually deleting some files), due to the running server retaining file locks.

A fail-proof approach for redeployment into Tomcat and TomEE is as follows:

  • Stop the server.

  • Delete the server's webapps\<app> folder.

  • Delete the server's webapps\<app>.war file.

  • Copy the new WAR file into the server's webapps folder.

Manual Deployment to SAP Business Technology Platform – Cloud Foundry Environment

Using SAP Business Technology Platform Cockpit for Cloud Foundry

This procedure refers to the SAP Business Technology Platform Cockpit, and is subject to change if the cockpit UI changes. If in doubt, please consult the Develop Applications topic in the SAP Business Technology Platform documentation.

If you don't yet have a SAP Business Technology Platform account for Cloud Foundry, start by signing up.

  1. Once you are in the cockpit, navigate to your Subaccount, then your Space.

  2. Click on the Deploy Application button.

  3. For the File Location, browse to the WAR file in your project's target folder.

  4. For the Manifest Location, browse to the manifest.yml in your project folder.

  5. Click on the Deploy button.

  6. See also Securing the Generated Service.

Using the cf Command-Line Tool

If not already done, Install Cloud Foundry Tools.

  • Use the cf api command to select your target Cloud Foundry environment.

  • Use the cf login command to authenticate yourself with Cloud Foundry.

  • Use the cf push command to deploy your application to Cloud Foundry.

  • Use the cf routes command to find the URL for accessing your service.

Example push command:

cf push -f c:\projects\myapp\manifest.yml

Last update: November 18, 2021