Manual Configuration

This section walks you through integrating Atoti Limits with the Atoti Server Java API.

note

We recommend using the simpler Auto Configuration approach.

Configurations in the module

In limits.properties, configure the following properties:

Atoti Server Instance parameters

Some parameters are needed in order to allow Atoti Limits to discover and communicate with the connected Atoti Server Instance.

Property Description
ap.url.map Mapping of the Atoti Server Instance name to the URL of its /pivot/rest/vX/cube.
vX should be replaced with the corresponding version identifier for your Atoti Server version.
ap.asOfDate.dim.map Mapping of the AsOfDate dimension, hierachy, and level of the Atoti Server Instance. “Level@Hierarchy@Dimension”
ap.auth.map Mapping of the Atoti Server Instance’s credentials to use to create new KPIs and read Cube structures, such as dimensions and measures. This is a Base64 encoded “User:Password” string.
limits.rest.url The URL where Limit’s REST APIs are located, Ex: http://localhost:3090/limits/rest/v2/.
limits.auth The authentication to use in REST requests to the Limits server from the connected Servers.
content.server.url The URL of the remote Content Server. Ex: http://localhost:8080/frtb-starter/content/rest/v7
content.server.auth The encoded authentication to use in REST requests to the Content Server.
Solution Authentication

The encoded authentication is needed for Atoti Limits to be able to communicate with the connected Solution. This encoded string can easily be created using Java’s java.util.Base64 utility. The format of the encoded authentication is “user:password”. This encoded string will be used in the REST request header when communicating between different components remotely.

Here’s an example of how to generate the string using Java:

String encodedAuth = Base64.getEncoder().encodeToString(("user:password").getBytes())
// Value of encoded auth:
encodedAuth = "dXNlcjpwYXNzd29yZA=="

Here’s an example snippet of what these properties look like in the limits.properties file:

ap.url.map={'MRA': 'http://localhost:10010/risk-activepivot/activeviam/pivot/rest/v8/cube', 'FRTB': 'http://localhost:8080/frtb-starter/activeviam/pivot/rest/v8/cube'}

ap.configuration.kpi.path.map={'FRTB': 'configuration/kpis'}

ap.asOfDate.dim.map={'MRA': 'AsOfDate@Date@Dates', 'FRTB': 'AsOfDate@Date@Dates'}

ap.auth.map={'MRA': `dXNlcjpwYXNzd29yZA==`, 'FRTB': `dXNlcjpwYXNzd29yZA==`}

limits.rest.url=http://localhost:3090/limits/rest/v2/
limits.auth=dXNlcjpwYXNzd29yZA==

content.server.url=http://localhost:8080/frtb-starter/activeviam/content/rest/v7
content.server.auth=dXNlcjpwYXNzd29yZA==

Path to the incident directory

note

The path needs to be part of the input.data.root.dir.path because we save incidents to a given server’s dedicated ‘incident’ directory (ie: /FRTB/incident). We also read this directory when incidents are loaded as a bulk operation.

incident.output.data.dir.path=${input.data.root.dir.path}/data
task-scheduler-thread-pool-size=4

Intraday Observation Frequency

Alert task is automatically scheduled based on the following setting:

  • sample-rate-cron=0 */5 * * * *

Parent-Child hierarchies

For Scopes of Parent-Child hierarchies, the hierarchy name can optionally be provided. However, if there are multiple hierarchies that contain the same level name, then the hierarchy will need to be specified with the level name. The format for this is: @=. Example: Level 5@BookHierarchy=IR_TRADING.

Testing properties

Target directory for Export

limit_export.target_dir=extractionOutput

Test file’s path for Upload

limit_upload.file_path=limits_approve_uploadTest.csv

note

For testing limit upload and export, the following properties must be set either in properties file or as Spring arguments.

Reference Data

  • limits_approve_mra.csv is for Atoti Market Risk. By default, it is located under limits-starter/src/test/resources/data-samples/data/2018-09-28 and loaded during startup.
  • limits_approve_frtb.csv is for Atoti FRTB, located in limits-starter/src/test/resources/data-samples/data/. Please relocate it to the “date” folder if you run Atoti Limits with FRTB.

Changes in Atoti Server

In order for Atoti Server to work with the module, Solutions need to add the following:

Include the dependencies in the pom.xml

For the LevelPath restful endpoint:

<dependency>
         <groupId>com.activeviam.apps</groupId>
         <artifactId>services</artifactId>
         <version>1.15.0-AS6.0</version>
   </dependency>

LookupPostProcessor:

Depending on your Atoti Server version, import the appropriate artifact according. For 5.9, 5.10 and 5.11:

       <dependency>
            <groupId>com.activeviam.limits</groupId>
            <artifactId>lookup-post-processor-ap59</artifactId>
            <version>{LIMIT MODULE VERSION}</version>
        </dependency>
       <dependency>
            <groupId>com.activeviam.limits</groupId>
            <artifactId>lookup-post-processor-ap510</artifactId>
            <version>{LIMIT MODULE VERSION}</version>
        </dependency>
       <dependency>
            <groupId>com.activeviam.limits</groupId>
            <artifactId>lookup-post-processor-ap511</artifactId>
            <version>{LIMIT MODULE VERSION}</version>
        </dependency>
       <dependency>
            <groupId>com.activeviam.limits</groupId>
            <artifactId>lookup-post-processor-ap60</artifactId>
            <version>{LIMIT MODULE VERSION}</version>
        </dependency>

Register the LookUpPostProcessor

The LookUpPostProcessor needs to be registered within Atoti Server for Atoti Server to be able to use it. You can register the LookUpPostProcessor statically anywhere in your Atoti Server configuration with the following:

      LookUpPostProcessor.addMeasureToRegistry();

Add the LevelPathRestServiceConfig

import com.activeviam.services.levelpath.LevelPathRestServiceConfig;

@Configuration
@Import(value = {
LevelPathRestServiceConfig.class
}

If your AP is running with AP 6.0, the LevelPath config should look like this:

import com.activeviam.services.levelpath.LevelPathRestService;
@Configuration
@Import(value = {
        LevelPathRestService.class
}

note

Ensure that within the ActivePivotConfig of your connected accelerator, the contextValueManager method is not setting the ActivePivotContentService to null. If the ActivePivotContentService is null, KPIs will not appear in the UI.

contextValueManager.setActivePivotContentService(this.apCSConfig.activePivotContentService());

Startup Sequence Matters

As Atoti Limits creates the KPI in the business cubes automatically, it is important to start up the business Atoti Server instances fully before starting up Atoti Limits.