Navigation :
test ../../ test user-ref.html
User & Reference Guide
test ../../ test getting-started.html
Getting started
test ../../ test getting-started/using-this-guide.html
- Using this guide
test ../../ test getting-started/whats-new.html
- What's New
test ../../ test getting-started/frtb-data-model.html
- FRTB Data Model
test ../../ test getting-started/directquery.html
- DirectQuery
test ../../ test configuration.html
Configuration files
test ../../ test datastore.html
Data Stores
test ../../ test database.html
Database
test ../../ test input-files.html
Input Data
test ../../ test tutorials.html
Tutorials
test ../../ test tutorials/data-sanity-check.html
- Data Sanity Check
test ../../ test tutorials/tips-for-validating-the-calculations.html
- Tips for Validating the Calculations
test ../../ test tutorials/viewing-qis-numbers.html
- Viewing QIS Numbers
test ../../ test interpret-impl.html
Interpretation and Implementation of the MAR standard
test ../../ test cube.html
Analytics Reference
test ../../ test dev.html
Developer Guide
test ../../ test dev/dev-release.html
-
Release and migration notes
test ../../ test dev/dev-getting-started.html
-
Getting Started
test ../../ test dev/dev-ref-impl.html
-
FRTB Reference Implementation
test ../../ test dev/dev-core.html
-
FRTB Core
test ../../ test dev/dev-extensions.html
-
Extending the Accelerator
test ../../ test dev/dev-extensions/add-a-new-cube-hierarchy.html
-- Adding New Cube Hierarchies
test ../../ test dev/dev-extensions/add-a-new-cube-measure.html
-- Adding New Cube Measures
test ../../ test dev/dev-extensions/replace-a-cube-measure.html
-- Replacing Cube Measures (Alpha Preview)
test ../../ test dev/dev-extensions/add-a-new-data-loading-unloading-topic.html
-- Adding New Data Loading or Unloading Topics
test ../../ test dev/dev-extensions/organizing-client-customizations-into-seperate-class.html
-- Organizing Datastore Helper Customizations into a Separate Class
test ../../ test dev/dev-extensions/add-a-new-kpi.html
-- Adding New KPIs
test ../../ test dev/dev-extensions/channel-parameter-beans.html
-- Replacing ChannelParameters Spring beans
test ../../ test dev/dev-extensions/add-and-load-new-column-to-existing-file.html
-- Adding and Loading New Columns to an Existing File
test ../../ test dev/dev-extensions/enriching-file-field-adding-column-calculators.html
-- Enriching File Fields by Adding Column Calculators
test ../../ test dev/dev-extensions/set-up-context-values.html
-- Setting up context values
test ../../ test dev/dev-extensions/dev-guidelines.html
--
Developing on the Accelerator
test ../../ test dev/dev-tools.html
-
Configuring Accelerator tools and methodologies
test ../../ test dev/dev-sign-off.html
-
Sign-Off
test ../../ test limits.html
Limit monitoring
test ../../ test sign-off.html
Sign-Off Approvals
test ../../ test what-if.html
What-If Analysis
test ../../ test pdf-guides.html
PDF Guides
test ../../ test glossary.html
Glossary
Adding New KPIs
This page provides a description of how we can add a KPI. The techniques employed are generic examples that can be extended, adapted and repeated for any use
case that we need. In all cases, we make minimal changes to the Accelerator Reference Implementation.
A KPI can be defined as a bean with the following format:
To define a KPI, create a bean with a Qualifier in the following format kpi[cubeNameHERE]
. Below is an example of a KPI on the FRTBCombinedCube
Be sure to include our configuration class which contains our bean(s) in the application config class FRTBConfig
located
in /frtb-starter/src/main/java/com/activeviam/frtb/starter/cfg/impl/
@Bean
@Qualifier ( "kpiFRTBCombinedCube" )
public IKpiDescription myKpiTest () {
return StartBuilding. kpi ()
. withName ( "myName" )
. withValue ( new KpiValueDescription( "[Measures].[MyMeasure]" ))
. withStatus ( new KpiStatusDescription(
"Case\n" +
"When IsNull(KpiValue(\"MyMeasure\"))\n" +
"Then NUll\n" +
"When 0.7 > KpiValue(\"MyMeasure\")\n" +
"Then -1\n" +
"When KpiValue(\"MyMeasure\") > 0.8\n" +
"Then 1\n" +
"Else 0\n" +
"End" ,
"Shapes" ))
. build ();
}
Pre-defined KPIs are located in the class KpiProviderConfig
within /frtb-starter/src/main/java/com/activeviam/frtb/starter/cfg/impl/