Analytic Engine Capabilities

The Analytic Engine capability enables the management of analytic instance lifecycles as well as runtime state.

Capability ID: predix.edge.analyticengine

Version: 1.0.0

Commands
startAnalyticsTemplate
Starts the analytic template associated with templateId.
Table 1. startAnalyticsTemplate Parameters
ParameterTypeDescription
templateIdString representing an integerAn identifier representing the analytic to be acted upon
stopAnalyticsTemplate
Stops the analytic template associated with templateId.
Table 2. stopAnalyticsTemplate Parameters
ParameterTypeDescription
templateIdString representing an integerAn identifier representing the analytic to be acted upon
deleteAnalyticsTemplate
Removes the analytic template associated with templateId, the analytic should no longer be reported in the status.
Table 3. deleteAnalyticsTemplate Parameters
ParameterTypeDescription
templateIdString representing an integerAn identifier representing the analytic to be acted upon
Packages
analytics_template
An analytic template that can be used to instantiate an analytic or that can be used in conjunction with a data map to instantiate an analytic.
Table 4. analytics_template Parameters
ParameterTypeDescription
nameStringName of the analytic template
descriptionStringDescription of the analytic template
idString representing an integerID of the analytic template
versionStraing representing a version (e.g., 1.0.0)Version of the analytic template
analytics_data_map
An analytic data map that can be used to instantiate an analytic based on a previously deployed analytic template.
Table 5. analytics_data_map Parameters
ParameterTypeDescription
nameStringName of the analytic template
descriptionStringDescription of the analytic template
idString representing an integerID of the analytic template
versionStraing representing a version (e.g., 1.0.0)Version of the analytic template
parentIdring representing an integerID of the template this data map is associated with

Status

Status message JSON schema:
{

       "$schema": "http://json-schema.org/draft-07/schema#",
       "type": "object",
       "required": [
              "component_status_list",
              "timestamp",
              "attributes"
    ],
    "properties": {
            "component_status_list":
            {
                "$ref": "#/definitions/component_status_list"
            },
            "timestamp":
            {
                "$ref": "#/definitions/timestamp"
            },
            "attributes":
            {
                "$ref": "#/definitions/attributes"
            }
    },
    "definitions": {
        "component_status_list": {
                    "$id": "#/definitions/component_status_list",
                    "type": "object",
                    "required": [
                           "status"
                    ],
                    "properties": {
                           "status": {
                    "type":"array",
                    "items":{
                        "$ref":"#/definitions/status_element"
                    }
                }
                    }
        },
        "status_element": {
            "type": "object",
            "required": [
                "id",
                "state",
                "state_message"
            ],
            "properties": {
                "id": {
                    "type": "string",
                    "pattern": "^[0-9]+$"
                },
                "state": {
                    "type": "string",
                    "enum":["EDGE_ANALYTICS_COMPONENT_STATE_ACTIVE", "EDGE_ANALYTICS_COMPONENT_STATE_INACTIVE", "EDGE_ANALYTICS_COMPONENT_STATE_UNKNOWN"]
                },
                "state_message": {
                    "type": "string",
                    "examples": [
                        "Running"
                    ],
                    "pattern": "^.+$"
                }
            }
        },
              "timestamp": {
                    "$id": "#/definitions/timestamp",
                    "type": "string",
                    "examples": [
                           "2018-12-11T17:58:53.171Z"
                    ],
                    "pattern": "^.+$"
              },
              "attributes": {
                    "$id": "#/definitions/attributes",
                    "type": "object",
            "^(.+)/([^/]+)$": {
                "$ref":"#/definitions/attributes_element"
            }
        },
        "attributes_element":{
            "$id": "#/definitions/attributes_element",
            "type":"object",
            "required": [
                "value"
            ],
            "properties": {
                "value": {
                    "type": "string"
                },
                "dataType": {
                    "type": "string",
                    "enum":["DATATYPE_STRING", "DATATYPE_BINARY", "DATATYPE_BOOLEAN","DATATYPE_FLOAT","DATATYPE_DOUBLE", "DATATYPE_INT","DATATYPE_LONG","DATATYPE_TIMESTAMP"]
                }
            }
        }
       }
}