Building & deploying Atoti Market Risk

Building the Project

Maven Repositories

  • From the ActiveViam share page, download the Maven repository for the version of Atoti Server the application is based on. This is specified in the release notes of the application you are deploying. The zip file containing the Maven repository will be called maven-repository-<version number>.zip.

  • From the Distribution folder, download the Maven repository for Atoti Market Risk (this contains all dependencies required to build Atoti Market Risk that aren’t included in the Atoti Server download). A zip file containing the Maven repository will be called mr-<version number>-maven-repository.zip.

Add these repositories to your existing Maven repository.

Source

From the Distribution folder, download and unzip the source files. The zipped file will be called market-risk-<version number>.zip.

Build

  1. Once you have added all the Maven repositories and extracted the source code, run mvn install on the parent pom file to build the entire project.

    This will build the Atoti Server executable JAR file (mr-application/target/mr-application-exec.jar)

  2. When the build is complete, you must deploy it. See Deployment

  3. Build the standalone UI application using npm or yarn, or download the prebuilt application from the distribution folder.

  4. Deploy the UI application.

Configuration

See Project configuration.

Deployment

Atoti Server

The mr-application is a Spring Boot application that builds an executable JAR. To deploy the executable JAR files, use the following command:

java -jar mr-application-exec.jar

To configure the port and context path of the application, two properties are used: server.port and server.servlet.context-path. The default values are in resources/application.yaml, the standard configuration file for Spring Boot applications.

For example:

java -jar mr-application-exec.jar --server.port=<port>

This can also be changed by externalizing the properties files (see Externalising Properties Files).

Atoti Server will be available at: http://<your hostname>:10010/mr-application/

Atoti UI

Atoti UI is a static website that can be deployed in any way you see fit. All the necessary files are to be found in the /build folder after the project has been built.

The UI should be built using Yarn or NPM. If customizations are not required, a prebuilt UI is available in the distribution folder.

Externalizing Properties Files

In the default implementation, all the necessary properties are within the project. A number of properties files have been externalized and can be overridden with an external file using JVM variables. You may wish to use this functionality if you are running the project in different environments. Below is a list of the files together with their respective variable names:

There are two options to override default properties:

  • OPTION 1: Command line arguments, for example: –csvSource.dataset=/path/to/folder .

    note

    we are using “--”, instead of “-D” to set properties with Spring Boot.

  • OPTION 2: Create a properties file, for example: application.properties and add your property overrides. Then pass it to the main using the command line argument: –spring.config.additional-location=/<path>/application.properties