Remote User Monitoring API

Portal Server Remote User Monitoring API Specification

Abstract

The “Remote User Monitoring API” is a WebSocket API that supports developers to implement their own version of a Synthetic Monitoring “Real Time Dashboard”.

Similar to the Remote User API there is also an “API Authentication Token” required to access the API.

“alt attribute”

API Functions

The API supports the following functions (so-called “actions”):

  • pingPortalServer : Ping the Portal Server at API level.
  • subscribeToHeartbeat : Subscribe to a periodic timestamp which is received every second.
  • unsubscribeFromHeartbeat : Cancel subscription to ‘subscribeToHeartbeat’.
  • subscribeToPeriodicAliveThread: Same functionality as ‘subscribeToHeartbeat’, but the time interval (in seconds) can be specified arbitrarily.
  • unsubscribeFromPeriodicAliveThread: Cancel subscription to ‘subscribeToPeriodicAliveThread’.
  • subscribeToRealtimeMonitor : Subscribe to events when a Monitoring Group or a Monitoring Job is created, modified or deleted, and subscribe to be notified each time when a Monitoring Group or a Monitoring Job is executed.
  • unsubscribeFromRealtimeMonitor : Cancel subscription to ‘subscribeToRealtimeMonitor’.
  • subscribeToMonitoringAlerts : Subscribe to monitoring alerts.
  • unsubscribeFromMonitoringAlerts : Cancel subscription to ‘subscribeToMonitoringAlerts’.
  • subscribeToGroupExecutionHistoryCache : Subscribe to a monitoring group’s execution history cache, which contains the measured data over the last 24 hours. The received data can be used to draw a chart or sparkline of the corresponding monitoring group.
  • unsubscribeFromAllGroupExecutionHistoryCaches : Cancel subscription to ‘subscribeToGroupExecutionHistoryCache’ for all monitoring groups.
  • subscribeToJobExecutionHistoryCache : Subscribe to a monitoring job’s execution history cache, which contains the measured data over the last 24 hours. The received data can be used to draw a chart or sparkline of the corresponding monitoring job.
  • unsubscribeFromAllJobExecutionHistoryCaches : Cancel subscription to ‘subscribeToJobExecutionHistoryCache’ for all monitoring jobs.
WebSocket URL
wss://portal.realload.com/RemoteUserMonitoringAPI
HTTP Request Header Fields
x-api-key: <API Authentication Token> required
subscribeToHeartbeat: true optional
subscribeToRealtimeMonitor: true optional

The subscribed data are received in JSON format. The received JSON values are never null.

Runtime Behavior

  • When the WebSocket connection is closed, all subscriptions are terminated.
  • When you send an “action”, the action is confirmed with a response frame with the name of the action repeated (except for “pingPortalServer”).
  • If you send an invalid “action”, the WebSocket connection will be closed.
  • The WebSocket connection doesn’t last forever. It will be closed after a few hours by the Portal Server. You then have to reestablish the WebSocket connection and renew the subscriptions.

Example:

Send: {"action":"subscribeToHeartbeat"}
Received: {"action":"subscribeToHeartbeat","isError":false}
Received: {"action":"heartbeat","timestamp":1708466543962,"isError":false}
Received: {"action":"heartbeat","timestamp":1708466544963,"isError":false}
Received: {"action":"heartbeat","timestamp":1708466545963,"isError":false}

Implementation Recommendations

  • We recommend that you implement two hash maps on the client side which contain the current configuration data of the monitoring jobs and monitoring groups - based on the actions of onMonitoringGroupEvent and onMonitoringJobEvent received from subscribeToRealtimeMonitor (hash map keys = Monitoring Group ID, Monitoring Job ID).
  • Preferably use a WebSocket client framework that can detect the closure of the WebSocket connection to the server. If this is not possible, use “subscribeToPeriodicAliveThread” or “pingPortalServer”.

pingPortalServer

Example:

Send: {"action":"pingPortalServer"}
Received: {"action":"pongFromPortalServer","portalServerVersion":"4.8.35","portalServerTimestamp":1708468300516,"isError":false}

subscribeToHeartbeat

  • Send action : “subscribeToHeartbeat”
{
  "action":"subscribeToHeartbeat"
}
  • Received action: “heartbeat”
{
  "action":"heartbeat",
  "timestamp":1677521478771,
  "isError":false
}

subscribeToPeriodicAliveThread

  • Send action : “subscribeToPeriodicAliveThread”
{
  "action":"subscribeToPeriodicAliveThread",
  "periodicIntervalSeconds":60
}
  • Received action: “periodicAlive”
{
  "action":"periodicAlive",
  "timestamp":1708469366167,
  "isError":false
}

subscribeToRealtimeMonitor

  • Send action : “subscribeToRealtimeMonitor”
{
  "action":"subscribeToRealtimeMonitor"
}
  • Received actions:
    • onMonitoringGroupEvent(The configuration data of a monitoring group)
    • onMonitoringJobEvent(The configuration data of a monitoring job)
    • onMonitoringGroupExecuted(The execution result of a monitoring group)
    • onMonitoringJobExecuted(The execution result of a monitoring job)
    • onMonitoringGroupTemporarilyEvent(Notification whether a monitoring group is temporarily disabled)
    • onMonitoringJobTemporarilyEvent(Notification whether a monitoring job is temporarily disabled)

As first you will receive instantly the configuration data of all already defined Monitoring Groups and Monitoring Jobs, and also the data of the last Execution Result of the Monitoring Groups and Monitoring Jobs (if they have been executed in the past).

After that you will receive update information of all Monitoring Groups and Monitoring Jobs when they are new-defined/modified/deleted, and you will receive also update information about the result of executed Monitoring Groups and Monitoring Jobs.

Because monitoring groups and jobs can be temporarily disabled by configuring one or multiple “Monitoring Downtime(s)” you receive the actions “onMonitoringGroupTemporarilyEvent” and “onMonitoringJobTemporarilyEvent”. “alt attribute”

Notifications for Monitoring Groups

  • Received action: “onMonitoringGroupEvent”
  • monitoringGroupAction:
    • “groupExists”
    • “groupAdded”
    • “groupModified”
    • “groupDeleted”
{
  "action": "onMonitoringGroupEvent",
  "monitoringGroupId": 34,
  "monitoringEvent": {
    "eventTimestamp": 1708541771774,
    "monitoringGroup": {
      "monitoringGroupId": 34,
      "ownerUserId": 13,
      "title": "First Group",
      "description": "",
      "maxDataStorageDays": 14,
      "agentType": "agent",
      "executionEnabled": true,
      "executionInterval": 300,
      "executionTimeout": 300,
      "currentExecutionState": "executing",
      "lastExecutionStartTime": 1708541763897
    },
    "monitoringGroupAction": "groupExists"
  },
  "isError": false
}

The executionInterval and the executionTimeout are in seconds. The lastExecutionStartTime has a value of -1 (minus one) if the Monitoring Group was never executed. The agentType has currently no meaning.

Any modification of a Monitoring Group made by the Portal Server Web Interface such as modify executionEnabled or title effects that a new frame with monitoringGroupAction = “groupModified” is received.

Notification for Monitoring Jobs

  • Received action: “onMonitoringJobEvent”
  • monitoringJobAction:
    • “jobExists”
    • “jobAdded”
    • “jobModified”
    • “jobDeleted”
{
  "action": "onMonitoringJobEvent",
  "monitoringGroupId": 36,
  "monitoringJobId": 79,
  "monitoringEvent": {
    "eventTimestamp": 1708541771790,
    "monitoringJobProperties": {
      "performanceErrorAlertThresholdMillis": "-1",
      "enableJobExecution": "true",
      "performanceWarningAlertsEnabled": "false",
      "testjobConcurrentUsers": "1",
      "testjobDelayPerLoop": "1000",
      "testjobDebugMeasuring": "false",
      "performanceErrorAlertsEnabled": "false",
      "enableAutomaticFileSync": "false",
      "performanceWarningAlertThresholdMillis": "-1",
      "testjobMaxTestDuration": "60",
      "testjobDebugExecution": "false",
      "testjobRampUpTime": "5",
      "definedFromMonitoringGroupId": "36",
      "testjobMaxLoopsPerUser": "1",
      "productVersion": "4.8.35",
      "monitoringJobId": "79",
      "monitoringJobTitle": "Local_Cinema",
      "lastExecutionStartTime": "1708541731138",
      "testjobAdditionalArguments": "",
      "definedFromTestId": "399",
      "testjobUserInputFieldsValuesJsonArray": "[]",
      "monitoringJobDescription": ""
    },
    "monitoringTestProperties": {
      "referencedResourceFilesList": [
        {
          "projectId": 130,
          "testplanId": 203,
          "fileName": "com.dkfqs.tools.jar"
        }
      ],
      "jsonConfigObject": {},
      "executingScript": "Local_Cinema.jar",
      "executingScriptResourceFileList": "",
      "createTimeStamp": "1708293851731",
      "testDescription": "",
      "definedFromTestplanId": "287",
      "productVersion": "4.8.34",
      "definedFromProjectId": "137",
      "visibleTestName": "Local_Cinema",
      "scriptType": "OpenJDK11Jar",
      "testId": "399"
    },
    "monitoringTestIsHealthy": true,
    "monitoringJobAction": "jobExists"
  },
  "isError": false
}

The testjobMaxTestDuration and the testjobRampUpTime are in seconds. The testjobDelayPerLoop are in milliseconds. The lastExecutionStartTime has a value of -1 (minus one) if the Monitoring Job was never executed.

Any modification of a Monitoring Job made by the Portal Server Web Interface such as modify enableJobExecution or monitoringJobTitle effects that a new frame with monitoringJobAction = “jobModified” is received.

Notification for Monitoring Group Execution

  • Received action: “onMonitoringGroupExecuted”
  • oldEvent: true or false | Note: the oldEvent is true at the first time (if the monitoring group was executed in the past) and then will always be false each time when the monitoring group is executed.
{
  "action": "onMonitoringGroupExecuted",
  "monitoringGroupId": 34,
  "monitoringEvent": {
    "eventTimestamp": 1708541771806,
    "oldEvent": true,
    "groupExecutionResult": {
      "magicPattern": "MonitoringGroupExecutionResult",
      "productVersion": "4.8.35",
      "userId": 13,
      "monitoringGroupId": 34,
      "groupExecutionId": 39412,
      "resultTimestamp": 1708541492973,
      "monitoringJobIdToLocalTestjobIdArray": [
        {
          "monitoringJobId": 60,
          "localTestjobId": 73932
        },
        {
          "monitoringJobId": 61,
          "localTestjobId": 73934
        },
        {
          "monitoringJobId": 62,
          "localTestjobId": 73933
        }
      ],
      "groupSystemStatus": 0,
      "groupCombinedTestjobState": "completed",
      "groupExecutionLogArray": [
        "2024-02-21 19:51:03.915 |  | INFO | Monitoring Group Execution Thread started",
        "2024-02-21 19:51:32.972 |  | INFO | Monitoring Job Id 60 executed",
        "2024-02-21 19:51:32.972 |  | INFO | Monitoring Job Id 62 executed",
        "2024-02-21 19:51:32.972 |  | INFO | Monitoring Job Id 61 executed",
        "2024-02-21 19:51:32.973 |  | INFO | Monitoring Group Execution Thread terminated"
      ],
      "numberOfPassedSamples": 10,
      "numberOfFailedSamples": 0,
      "numberOfPassedLoops": 6,
      "numberOfFailedLoops": 0,
      "sumErrorsSeverityWarning": 0,
      "sumErrorsSeverityError": 0,
      "sumErrorsSeverityFatal": 0
    }
  },
  "hasGroupExecutionStatistic": true,
  "groupExecutionStatistic": {
    "userId": 13,
    "monitoringGroupId": 34,
    "fromTimestamp": 1708455371812,
    "toTimestamp": 1708541771812,
    "systemAvailabilityPercent": 100,
    "measuredAvailabilityPercent": 100,
    "measuredFaultyTimeSumSeconds": 0
  },
  "isError": false
}

groupSystemStatus:

  • 0: Healthy = All monitoring jobs of the monitoring group have been started on all measuring agents.
  • -1 (minus one): Partial Malfunction = Some monitoring jobs of the monitoring group have not been started on some measuring agents.
  • -2 (minus two): Malfunction = No monitoring jobs of the monitoring group have been started on any measuring agent.

groupCombinedTestjobState

  • “completed”: All test jobs of the monitoring group have been successfully executed on all measuring agents.
  • “partial failed”: The execution of some of the test jobs of the monitoring group did fail on some measuring agents.
  • “failed”: The execution of all of the test jobs of the monitoring group did fail on all measuring agents.

Hint for groupCombinedTestjobState : Note that is value does not reflect if any warnings or errors have been measured by the test jobs.

The Reference Implementation on the Real Load Portal Server shows the measured (sumErrorsSeverityError + sumErrorsSeverityFatal) simple as “number of measured errors”.

Notification for Monitoring Job Execution

  • Received action: “onMonitoringJobExecuted”
  • oldEvent: true or false | Note: the oldEvent is true at the first time (if the monitoring job was executed in the past) and then will always be false each time when the monitoring job is executed.
{
  "action": "onMonitoringJobExecuted",
  "monitoringGroupId": 36,
  "monitoringJobId": 79,
  "monitoringEvent": {
    "eventTimestamp": 1708541771849,
    "oldEvent": true,
    "jobExecutionResult": {
      "magicPattern": "MonitoringJobExecutionResult",
      "productVersion": "4.8.35",
      "userId": 13,
      "monitoringGroupId": 36,
      "groupExecutionId": 39417,
      "monitoringJobId": 79,
      "localTestjobId": 73939,
      "resultTimestamp": 1708541748100,
      "systemStatus": 0,
      "jobExecutionLogArray": [
        "2024-02-21 19:55:31.137 |  | INFO | Monitoring Job Execution Thread started",
        "2024-02-21 19:55:31.495 | Shared Agent 1 | INFO | Job submitted to measuring agent, remote testjob id = 19015",
        "2024-02-21 19:55:38.034 | Shared Agent 1 | INFO | Job executed on measuring agent, exit code = process executed successfully",
        "2024-02-21 19:55:40.014 | Shared Agent 2 | INFO | Job submitted to measuring agent, remote testjob id = 4864",
        "2024-02-21 19:55:46.446 | Shared Agent 2 | INFO | Job executed on measuring agent, exit code = process executed successfully",
        "2024-02-21 19:55:48.100 |  | INFO | Monitoring Job Execution Thread terminated"
      ],
      "combinedTestjobState": "completed",
      "hasCombinedTestResult": true,
      "combinedTestResultFileName": "TestResult_MonitoringJob_79_2024-02-21@19-55-48.json",
      "combinedTestResultSummaryStatistic": {
        "productVersion": "4.8.35",
        "localTestjobId": 73939,
        "remoteTestjobId": 39417,
        "samplingGranularity": 4000,
        "jobStartTimestamp": 1708541736385,
        "jobEndTimestamp": 1708541744994,
        "osCpuLoadPercent": -1,
        "numberOfPassedLoopsTimeSum": 178,
        "numberOfConcurrentUsers": 0,
        "currentlyPendingSamples": 0,
        "numberOfPassedSamples": 2,
        "numberOfFailedSamples": 0,
        "numberOfPassedLoops": 2,
        "numberOfFailedLoops": 0,
        "numberOfMeasuredErrors": 0,
        "numErrorsSeverityWarning": 0,
        "numErrorsSeverityError": 0,
        "numErrorsSeverityFatal": 0
      },
      "averagePassedLoopTime": 89,
      "sumErrorsSeverityWarning": 0,
      "sumErrorsSeverityError": 0,
      "sumErrorsSeverityFatal": 0
    }
  },
  "hasJobExecutionStatistic": true,
  "jobExecutionStatistic": {
    "userId": 13,
    "monitoringGroupId": 36,
    "monitoringJobId": 79,
    "fromTimestamp": 1708455371849,
    "toTimestamp": 1708541771849,
    "systemAvailabilityPercent": 100,
    "measuredAvailabilityPercent": 100,
    "measuredFaultyTimeSumSeconds": 0,
    "averagePassedLoopTime": 93,
    "hasPassedLoopTimePercentileArray": false
  },
  "isError": false
}

systemStatus:

  • 0: Healthy = The monitoring job have been started on all measuring agents.
  • -1 (minus one): Partial Malfunction = The monitoring job was not started on some measuring agents.
  • -2 (minus two): Malfunction = The monitoring job was not started on any measuring agent.

combinedTestjobState

  • “completed”: The testjob was successfully executed on all measuring agents.
  • “partial failed”: The execution of the testjob did fail on some measuring agents.
  • “failed”: The execution of the testjob did fail on all measuring agents.

Hint for combinedTestjobState : Note that is value does not reflect if any warnings or errors have been measured by the test jobs.

The Reference Implementation of the Monitoring Dashboard on the RealLoad Portal Server shows the measured (sumErrorsSeverityError + sumErrorsSeverityFatal) simple as “number of measured errors”.

Notification for Monitoring Group Temporarily Event

  • Received action: “onMonitoringGroupTemporarilyEvent”
  • monitoringGroupTemporarilyAction: “groupExecutionTemporarilyNotDisabled” or “groupExecutionTemporarilyDisabled”
{
  "action": "onMonitoringGroupTemporarilyEvent",
  "monitoringGroupId": 34,
  "monitoringEvent": {
    "eventTimestamp": 1708541771851,
    "monitoringGroup": {
      "monitoringGroupId": 34,
      "ownerUserId": 13,
      "title": "First Group",
      "description": "",
      "maxDataStorageDays": 14,
      "agentType": "agent",
      "executionEnabled": true,
      "executionInterval": 300,
      "executionTimeout": 300,
      "currentExecutionState": "executing",
      "lastExecutionStartTime": 1708541763897
    },
    "monitoringGroupTemporarilyAction": "groupExecutionTemporarilyNotDisabled"
  },
  "isError": false
}

Notification for Monitoring Job Temporarily Event

  • Received action: “onMonitoringJobTemporarilyEvent”
  • monitoringJobTemporarilyAction: “jobExecutionTemporarilyNotDisabled” or “jobExecutionTemporarilyDisabled”
{
  "action": "onMonitoringJobTemporarilyEvent",
  "monitoringGroupId": 36,
  "monitoringJobId": 79,
  "monitoringEvent": {
    "eventTimestamp": 1708541771854,
    "monitoringJobProperties": {
      "performanceErrorAlertThresholdMillis": "-1",
      "enableJobExecution": "true",
      "performanceWarningAlertsEnabled": "false",
      "testjobConcurrentUsers": "1",
      "testjobDelayPerLoop": "1000",
      "testjobDebugMeasuring": "false",
      "performanceErrorAlertsEnabled": "false",
      "enableAutomaticFileSync": "false",
      "performanceWarningAlertThresholdMillis": "-1",
      "testjobMaxTestDuration": "60",
      "testjobDebugExecution": "false",
      "testjobRampUpTime": "5",
      "definedFromMonitoringGroupId": "36",
      "testjobMaxLoopsPerUser": "1",
      "productVersion": "4.8.35",
      "monitoringJobId": "79",
      "monitoringJobTitle": "Local_Cinema",
      "lastExecutionStartTime": "1708541731138",
      "testjobAdditionalArguments": "",
      "definedFromTestId": "399",
      "testjobUserInputFieldsValuesJsonArray": "[]",
      "monitoringJobDescription": ""
    },
    "monitoringJobTemporarilyAction": "jobExecutionTemporarilyNotDisabled"
  },
  "isError": false
}

subscribeToMonitoringAlerts

  • Send action : “subscribeToMonitoringAlerts”
{
  "action":"subscribeToMonitoringAlerts"
}
  • Received action: “onMonitoringAlert”
  • alertLevel: “Monitoring Group”, “Monitoring Job” or “Monitoring Job Measuring Agent”
  • alertType: “New Alert”, “Modified Alert”, “Repeated Alert” or “Canceled Alert”
{
  "action": "onMonitoringAlert",
  "monitoringEvent": {
    "eventTimestamp": 1708547148410,
    "monitoringAlert": {
      "userId": 13,
      "alertLevel": "Monitoring Group",
      "alertType": "New Alert",
      "alertId": 579,
      "alertContext": {
        "alertIdUpdateCounter": 0,
        "currentSystemStatus": "Healthy",
        "currentExecutionState": "Successful",
        "currentNumMeasuredWarnings": 0,
        "currentNumMeasuredErrors": 2,
        "previousSystemStatus": "Healthy",
        "previousExecutionState": "Successful",
        "previousNumMeasuredWarnings": 0,
        "previousNumMeasuredErrors": 0
      },
      "monitoringGroupId": 36,
      "monitoringGroupExecutionResult": {
        "magicPattern": "MonitoringGroupExecutionResult",
        "productVersion": "4.8.35",
        "userId": 13,
        "monitoringGroupId": 36,
        "groupExecutionId": 39525,
        "resultTimestamp": 1708547148390,
        "monitoringJobIdToLocalTestjobIdArray": [
          {
            "monitoringJobId": 79,
            "localTestjobId": 74083
          }
        ],
        "groupSystemStatus": 0,
        "groupCombinedTestjobState": "completed",
        "groupExecutionLogArray": [
          "2024-02-21 21:25:31.365 |  | INFO | Monitoring Group Execution Thread started",
          "2024-02-21 21:25:48.383 |  | INFO | Monitoring Job Id 79 executed",
          "2024-02-21 21:25:48.390 |  | INFO | Monitoring Group Execution Thread terminated"
        ],
        "numberOfPassedSamples": 0,
        "numberOfFailedSamples": 2,
        "numberOfPassedLoops": 0,
        "numberOfFailedLoops": 2,
        "sumErrorsSeverityWarning": 0,
        "sumErrorsSeverityError": 2,
        "sumErrorsSeverityFatal": 0
      }
    }
  },
  "isError": false
}

subscribeToGroupExecutionHistoryCache

  • Send action : “subscribeToGroupExecutionHistoryCache”
{
  "action": "subscribeToGroupExecutionHistoryCache",
  "monitoringGroupId": 36
}

Error Case

{
  "action": "subscribeToGroupExecutionHistoryCache",
  "isError": true,
  "genericErrorText": "subscribeToGroupExecutionHistoryCache failed: java.lang.IllegalArgumentException: Invalid monitoringGroupId : 35"
}

Received actions:

  • onMonitoringGroupExecutionHistoryInitialEntries(history data of the last 24 hours)
  • onMonitoringGroupExecutionHistoryNewEntry(last update of history data)
{
  "action": "onMonitoringGroupExecutionHistoryInitialEntries",
  "monitoringGroupId": 36,
  "monitoringEvent": {
    "eventTimestamp": 1708548777246,
    "historyEntriesArray": [
      {
        "t": 1708463444623,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "w": 0,
        "e": 0,
        "f": 0,
        "gid": 37851
      },
      {
        "t": 1708463504557,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "w": 0,
        "e": 0,
        "f": 0,
        "gid": 37853
      },
      {
        "t": 1708463563635,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "w": 0,
        "e": 0,
        "f": 0,
        "gid": 37854
      },
      {
        "t": 1708548588515,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "w": 0,
        "e": 2,
        "f": 0,
        "gid": 39554
      },
      {
        "t": 1708548648466,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "w": 0,
        "e": 2,
        "f": 0,
        "gid": 39555
      },
      {
        "t": 1708548708464,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "w": 0,
        "e": 2,
        "f": 0,
        "gid": 39557
      },
      {
        "t": 1708548768449,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "w": 0,
        "e": 2,
        "f": 0,
        "gid": 39558
      }
    ]
  },
  "isError": false
}
{
  "action": "onMonitoringGroupExecutionHistoryNewEntry",
  "monitoringGroupId": 36,
  "monitoringEvent": {
    "eventTimestamp": 1708549188525,
    "historyEntry": {
      "t": 1708549188468,
      "ge": 60,
      "ss": 0,
      "ct": "completed",
      "w": 0,
      "e": 2,
      "f": 0,
      "gid": 39566
    }
  },
  "isError": false
}
  • t : Unix-like timestamp
  • ge : Monitoring group execution interval (seconds)
  • ss : Group system status: 0 = HEALTHY, -1 = PARTIAL MALFUNCTION, -2 = MALFUNCTION
  • ct : Group combined test job state: “completed”, “partial failed” or “failed”
  • w : Sum of errors with severity warning
  • e : Sum of errors with severity error
  • f : Sum of errors with severity fatal
  • gid : Group execution ID

subscribeToJobExecutionHistoryCache

  • Send action : “subscribeToJobExecutionHistoryCache”
{
  "action": "subscribeToJobExecutionHistoryCache",
  "monitoringJobId": 79
}

Error Case

{
  "action": "subscribeToJobExecutionHistoryCache",
  "isError": true,
  "genericErrorText": "subscribeToJobExecutionHistoryCache failed: java.lang.IllegalArgumentException: Invalid monitoringJobId : 80"
}

Received actions:

  • onMonitoringJobExecutionHistoryInitialEntries(history data of the last 24 hours)
  • onMonitoringJobExecutionHistoryNewEntry(last update of history data)
{
  "action": "onMonitoringJobExecutionHistoryInitialEntries",
  "monitoringGroupId": 36,
  "monitoringJobId": 79,
  "monitoringEvent": {
    "eventTimestamp": 1708551216713,
    "historyEntriesArray": [
      {
        "t": 1708464823243,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "al": 118,
        "w": 0,
        "e": 0,
        "f": 0,
        "lid": 71889,
        "h": true
      },
      {
        "t": 1708464882694,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "al": 107,
        "w": 0,
        "e": 0,
        "f": 0,
        "lid": 71890,
        "h": true
      },
      {
        "t": 1708464943399,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "al": 96,
        "w": 0,
        "e": 0,
        "f": 0,
        "lid": 71891,
        "h": true
      },
      {
        "t": 1708550987656,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "al": -1,
        "w": 0,
        "e": 2,
        "f": 0,
        "lid": 74186,
        "h": true
      },
      {
        "t": 1708551047722,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "al": -1,
        "w": 0,
        "e": 2,
        "f": 0,
        "lid": 74187,
        "h": true
      },
      {
        "t": 1708551108599,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "al": -1,
        "w": 0,
        "e": 2,
        "f": 0,
        "lid": 74191,
        "h": true
      },
      {
        "t": 1708551167586,
        "ge": 60,
        "ss": 0,
        "ct": "completed",
        "al": -1,
        "w": 0,
        "e": 2,
        "f": 0,
        "lid": 74192,
        "h": true
      }
    ]
  },
  "isError": false
}
{
  "action": "onMonitoringJobExecutionHistoryNewEntry",
  "monitoringGroupId": 36,
  "monitoringJobId": 79,
  "monitoringEvent": {
    "eventTimestamp": 1708551228189,
    "historyEntry": {
      "t": 1708551228183,
      "ge": 60,
      "ss": 0,
      "ct": "completed",
      "al": -1,
      "w": 0,
      "e": 2,
      "f": 0,
      "lid": 74193,
      "h": true
    }
  },
  "isError": false
}
  • t : Unix-like timestamp
  • ge : Monitoring group execution interval (seconds)
  • ss : System status: 0 = HEALTHY, -1 = PARTIAL MALFUNCTION, -2 = MALFUNCTION
  • ct : Combined test job state: “completed”, “partial failed” or “failed”
  • al : Average passed loop time (milliseconds), -1 = no data
  • w : Sum of errors with severity warning
  • e : Sum of errors with severity error
  • f : Sum of errors with severity fatal
  • lid : Local test job ID
  • h: Has combined test result: true or false

Other Received Actions

You will also receive other actions than previously described above. These are confirmations that you can ignore. Example:

{
    "action":"subscribeToRealtimeMonitor",
    "isError":false
}