Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Development Environment Setup

This step-by-step guide explains how to set up your development environment, using either Eclipse or IntelliJ for the backend and web UI and Android Studio for the mobile app. Please follow it strictly to ensure that your code adheres to our guidelines and that development will run smoothly.

Please note that these instructions are optimized for Windows and Linux systems. If you're developing on a Mac, we would be glad to get your feedback about extending this guide with OS-specific instructions through our

SORMAS Project (web application)

Please note that these instructions are optimized for Windows and Linux systems. If you're developing on a Mac, we would be glad to get your feedback about extending this guide with OS-specific instructions through our GitHub Discussions.

Step 1: Check Out the SORMAS Repository

...

git config --global branch.development.rebase true

Step 2: Install JAVA

  • Download and install the Java 11 JDK (not JRE) for your operating system, which is also needed for the Server Setup. We suggest using Zulu OpenJDK. If you're running Linux, please refer to the official documentation on how to install Zulu OpenJDK on your system.

...

  • The SORMAS CI is using JDK 17 to build all modules. The only known difference though is slight differences in the Java time API that affect unit tests, so again there is no need to setup two JDKs on your local system.

Step 3: Install and configure IDE

Here we can see the step-by-step process of how to set up the SORMAS project in your local environment using an Integrated Development Environment(IDE) for Developers.

IntelliJ

Reference: click here

Project repository check-out process

...

Optional: Setup database access from Intellij: Open View -> Tool View -> Database, click on the + icon select DataSource -> PostgreSQL, and configure the database (set user and password and download the missing driver files if needed)

Eclipse(IDE)
  • Download and install the latest Eclipse IDE for Enterprise Java and Web Developers

  • Set the default JRE of Eclipse to the installed JDK: Assigning the default JRE for the workbench

  • Optional: Clone the SORMAS-Project repository if you haven't done so already via File -> Import -> Git -> Projects from Git and cancel the process when you're asked to create a new project from the cloned repository

  • Import the projects from the SORMAS-Project repository into your workspace via File -> Import -> Maven -> Existing Maven Projects

  • Install the Payara Tools plugin

  • Install the Vaadin Plugin for Eclipse; the commercial UI designer is not needed

  • Add a Payara server to Eclipse and enter the credentials you specified when setting up the local SORMAS server

  • Make a copy of sormas-base/dev.env.example, rename it to dev.env and set GLASSFISH_DOMAIN_ROOT to the location of the SORMAS domain inside your Payara installation

  • Either run mvn install on the sormas-base project or execute the dev/build.sh script (for example with Git Bash)

  • Execute dev/deploy-serverlibs.sh script

  • Highlight all Eclipse projects and choose Maven -> Update Project from the right-click menu; perform the update for all projects

  • Start the Glassfish server and deploy sormas-ear, sormas-rest, and sormas-ui by dragging the respective projects onto it, or use the Add and Remove... function by right-clicking on the server (make sure to respect this order as there are dependencies between artifacts at startup)

  • Open your browser and type in http://localhost:6080/sormas-ui to test whether the server and IDE have been set up correctly.

Android Studio

Please note: You only need to install Android Studio if you're developing code for the Android app. This is likely the case when you're adding new fields or entities to the system, or if you specifically want to work on the mobile app.

...

Important: Whenever you do or pull changes in the sormas-api project that you want to use in the mobile app or that are referenced there already, you need to execute the dev/build.sh script to notify the sormas-app project of the changes.

Configuration and Import settings

SORMAS App (Android application)

Android Studio setup

Project repository check-out process

Installation of supporting plugins

Data Synchronization

Version and Update

Device Encryption

Data Storage

Firebase Crashlytics & Performance Monitoring

SORMAS SERVER (LINUX)

Please find the details here