Steve Pisani · Feb 3, 2020 4m read

REST Business Activity Monitoring (rBAM) -Extending native BAM.

Hi All -   I want to share with the community a project I recently posted in OpenExchange, that extends on the Business Activity Monitoring features available with InterSystems IRIS’s integration  framework. I have called this REST Business Activity Monitoring, and is implemented via a set of zaux.rBAM.* classes. 


Background: Default IRIS Business Activity Monitoring functionality:             

First - some background for newcomers: For some time, IRIS (and previous products like Ensemble), provided developers with the ability to define classes that could expose metrics about the data flowing through and persisted within an integration solution, (ie - Business Metrics).  Additionally, the IRIS Analytics feature utilizes metric data to visually representing these user-defined business metrics in dashboards.

This feature is implemented by defining Business Metric classes (which are subclasses of Ens.BusinessMetric) that are developed and included within interoperability productions.

For example, an IoT solution receiving regular environmental readings from sensors may define a Business Metric class to expose the following information from data collected:

Property AverageDailyTemp              as Ens.DataType.Metric (Units = “Degrees”);
Property AirQuality                             as Ens.DataType.Metric (Units = “AQI”) [Multidimensional];

The implementation of the Business Metric functionality requires a developer to provide code in the Business Metric subclass to gather and populate the values of each metric property (in the above example, AverageDailyTemp, or AirQuality) within the class’s OnCalculateMetrics() method.

The online documentation for defining Business Metric classes can be found here
The online documentation for developing Dashboards to display business metrics in graphs, and other widgets, can be found here


The  'REST Business Activity Monitoring (rBAM)' - Extending native BAM Functionality:

The functionality referenced here and posted to the InterSystems' OpenExchange site extends the existing, pre-defined Business Metric framework in two ways, and assumes you have already developed and have enabled Business Metric classes in your production. These are the extensions: 

1. Capture and push (using HTTP POST) business metric values to a nominated REST endpoint.  This is useful if you want to capture metrics and update a remote system. For example – using this feature one can push the metric values to a Power BI Streaming dataset which can be then consumed by Microsoft Power BI Dashboards for real-time visualization in that framework. Note that IRIS also has the capability to consume and display Business Metrics natively in HTML dashboards, and has a wide range of graphical widgets to choose from for real-time dashboard (see: IRIS Business Activity Monitoring).    

2. Setup a REST API as an endpoint for external systems to call into IRIS and retrieve the list of business metric classes running in a production, as well as metric values of a one or all enabled Business Metric Classes 

It is worth mentioning that the above is accomplished without needing to modify, subclass or otherwise extend any existing Business Metric class code you have. This functionality taps into the tables currently defined by IRIS, that hold the most recently calculated metric values.


Follow the instructions outlined in the InterSystems' OpenExchange site found here.


Usage: POST Metric data using the provided Business Operation, to a nominated REST Endpoint.

Using this functionality you can post data periodically to any REST endpoint, for example,  you can setup a Microsoft Power BI real-time Streaming Dataset and send metrics to the endpoint provided by Power BI.  These values then be consumed using real-time Power BI Dashboards.

Metric data sent over REST is organised in iether a 'flat' or 'structured' output JSON formats, and, various settings are available on the Business Operation to filter metrics you do not want to publish, and aggregate metrics from multiple enabled and running Business Metric hosts. 

The READ.ME, and associated documentation of this package steps you through defining a Power BI real-time dashboard that is populated from IRIS Metric class data. The steps a Sample Production and Business Metric class so you do not have to build your own.


Usage: Serve Metric data through a REST API

The second feature of this code package is to provide a REST API which may be used to serve metric data to REST Clients that wish to retrieve these captured Business Metric values.  The documentation included with the package walks you through setting up the REST API endpoint in IRIS to enable this feature. Below is a summary of the API functionality:



I hope this functionality proves useful to others.  The tool is quiet comprehensive and supports both single value, and multi-dimensional metrics as well as metric Instances. 

The accompanying documentation available with the package download in PDF, describes all the various settings that govern the output, and output format of rendered metric values, as well as many other configuration settings and features. 

- Steve

1 0 0 116
Log in or sign up to continue