Sign-off API implementation in MRA
This page provides implementation details about the usage of the Sign-off API 1.0 library within MRA, focusing on configuration and included functionality. For documentation of the library itself, see Sign-off API.
Service implementations
SignOffService
The SignOffService class implements the ISignOffService interface, providing functionality for sign-off
related methods.
The initiate method
Uses a SignOffProcessKey parameter to create a branch using the key as its name. The base branch is always
master, and the service tracks the epoch of master that the branch was created from.
The approve method
Uses a SignOffProcessKey parameter to attempt to merge a Sign-off branch back into the master branch. The
merge will be rejected if the master branch has had subsequent commits. If a merge is successful, the
Sign-off branch will be dropped, to prevent performance issues inherent to holding branches in memory.
Due to the lack of a conflict resolution mechanism, tasks cannot be initiated and approved in parallel.
The export method
Parses a SignOffProcessInstanceExportDTO for the data necessary to create export orders through the Data
Connectors library.
The service creates store-level (using ISearchFactsQuery objects) and aggregated (using MDX generated through
Apache Velocity templates) export orders. Properties defined in the signoff.export.properties file are used to
determine which fields are included in the export.
The endpoint returns a set of three export task IDs for the request.
The status method
Retrieves the Data Connectors export status for a set of Sign-off tasks. The statuses of the three export tasks are grouped into a single response containing the execution statuses and details about the result of the exports.
The kpis method
Returns Goal, Value and Status details for a list of filtered KPIs. The details are retrieved by executing a
query against the running ActivePivot server.
SignOffRestService
The SignOffRestService class wraps the SignOffService in a set of REST endpoints.
SupportedAdjustmentsConfig
The SupportedAdjustmentsConfig class contains two Spring Beans that are autowired into the SupportedAdjustmentService,
providing specifications for adjustments on scalar sensitivities and PnLs.
AdjustmentsExecutionConfig
The AdjustmentExecutionConfig class exposes executors for the two supported adjustment types. Both types use the same
executor logic, which queries the datastore, clones the results and modifies the values to the input value.
The supported adjustments are add-ons, which aggregate directly with the unadjusted data. The adjustment input rows are tagged with the appropriate source and input type.
The adjustments are executed on a branch using the same key generator as the initiate and approve methods of the
SignOffService.
An adjustment is set as failed if any of the following occur:
- Execution branch does not exist
- Request filters, measures or input do not match the supported adjustment specification
- Datastore query does not return any results
- Errors are thrown during datastore transactions
AdjustmentPivotConfig
The AdjustmentPivotConfig class adds a sign-off adjustment source-tagging dimension to the Sensitivity and PL cubes.
SignOffDatastoreCustomisations
Sign-off adjustment source-tagging datastore fields are added in the SignOffDatastoreCustomisations class, using
the Accelerator Common Library and the Datastore Helper.
SignOffRestServiceConfig
The SignOffRestServiceConfig class adds the SignOffRestService and AdjustmentRestService services to the ActivePivot
REST services.