Skip to content

Backend Deployment to Azure

Ophir Katz edited this page Jun 24, 2018 · 7 revisions

This section describes the process of deploying the backend system to the Azure service.

Note: The project is not always deployed and running in Azure. It is hosted on the server of the Industrial Engineering faculty in the Technion, along with other system components.

Azure hosts a resource called WebApp service, which can host and run our backend on a live server.


In order to create a webapp service in azure, please refer to the following Microsoft documentation.


The deployment process itself was handled very easily using Azure Toolkit For IntelliJ (install here, or from within intelliJ itself, following this guide).

After installing the toolkit plugin, there should now be a small icon for Azure in the project's description, with a "Run on Web App" option:


Before deploying, some changes need to be made in the pom.xml of the 'code' section of the project. These changes are due to the structure of the project, causing the deployment to succeed, but not handle requests since Request Timeout (HTTP 500) response is returned.

The first change - comment out the sourceDirectory tag child in the pom.xml files' build tag parent.

Another change to the pom is depicted in the following gif (removing comments from a few lines of code):


After this small change, you can now deploy the backend of this project to azure by defining the web app service you want to use (from within intelliJ, via the Azure toolkit). After that, the deployment process will run and at the end, you should see something similar to this:


Notable error messages and how to fix them:

  1. You might get an error complaining about broken Auth. This happens because the session with Azure is disconnected. The fix is to logout via intelliJ (Tools->Azure->Azure Sign Out), and then log back in with your Azure credentials (Tools->Azure->Azure Sign In).

  2. You might get an error after the process has packaged your project saying that it cant find the jar file. This is because the configured jar file in the Run on Web App form is different than the one you defined in your pom.xml file. Match the two and it will be fixed.

  3. You might get an error just before the deployment is over, that says that the timeout was exceeded. This is because the jar file is very large, and the connection with the server has timed out. In general, you should keep your pom file as skinny as possible, to make sure the jar file is not too big, but the simple fix for this is to try again (after executing mvn clean), and it should be OK.

Clone this wiki locally