Class Reference
IRIS for UNIX 2019.2
InterSystems: The power behind what matters   
Documentation  Search
  [%SYS] >  [SYS] >  [Monitor] >  [Alert]
Private  Storage   

persistent class SYS.Monitor.Alert extends %Persistent

Inventory

Parameters Properties Methods Queries Indices ForeignKeys Triggers
5 3


Summary

Properties
AlertTime Msg PrevState Sensor State

Methods
%AddToSaveSet %AddToSyncSet %BMEBuilt %CheckConstraints
%CheckConstraintsForExtent %ClassIsLatestVersion %ClassName %ComposeOid
%ConstructClone %Delete %DeleteExtent %DeleteId
%DispatchClassMethod %DispatchGetModified %DispatchGetProperty %DispatchMethod
%DispatchSetModified %DispatchSetMultidimProperty %DispatchSetProperty %Exists
%ExistsId %Extends %GUID %GUIDSet
%GetLock %GetParameter %GetSwizzleObject %Id
%InsertBatch %IsA %IsModified %IsNull
%KillExtent %KillExtentData %LoadFromMemory %LockExtent
%LockId %New %NormalizeObject %ObjectIsNull
%ObjectModified %Oid %OnBeforeAddToSync %OnDetermineClass
%Open %OpenId %OriginalNamespace %PackageName
%PhysicalAddress %PurgeIndices %Reload %RemoveFromSaveSet
%ResolveConcurrencyConflict %RollBack %Save %SaveDirect
%SaveIndices %SerializeObject %SetModified %SortBegin
%SortEnd %SyncObjectIn %SyncTransport %UnlockExtent
%UnlockId %ValidateIndices %ValidateObject


Properties

• property AlertTime as %String [ Required ];
Date/Time of Alert
• property Msg as %String(MAXLEN=500);
Alert message
• property PrevState as %Integer [ Required ];
Previous state
• property Sensor as %String(MAXLEN=250);
Name of sensor
• property State as %Integer [ Required ];
Current state

Queries

• query Alerts(BeginTime As %String, EndTime As %String)
SQL Query :
SELECT *
FROM Alert
WHERE AlertTime BETWEEN :BeginTime AND :EndTime
Return the alerts for a given date/time range. Date/time is in $zdt($h,3) format.
• query AlertsBySensor(BeginTime As %String, EndTime As %String, Sensor As %String)
SQL Query :
SELECT *
FROM Alert
WHERE AlertTime BETWEEN :BeginTime AND :EndTime
AND Sensor = :Sensor
Return the alert(s) for a given sensor, for a given date/time range. Date/time is in $zdt($h,3) format.
• query HealthState()
SQL Query :
SELECT *
FROM Alert
WHERE AlertTime >= (SELECT MAX(AlertTime) FROM Alert WHERE PrevState = 0)
Return the alerts between current state, and previous green state


Copyright (c) 2019 by InterSystems Corporation. Cambridge, Massachusetts, U.S.A. All rights reserved. Confidential property of InterSystems Corporation.