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

persistent class %SYS.Monitor.Sensor extends %Persistent

The persistent definition of a System Monitor Dashboard Sensor. This also includes the history of all Sensor Readings.

Inventory

Parameters Properties Methods Queries Indices ForeignKeys Triggers
12 7 4 1


Summary

Properties
Alert CriticalValue Description Item
Name Operator ReadingInterval Readings
Units WarningValue

Methods
%%CLASSNAMELogicalToStorage %%CLASSNAMEStorageToLogical %AddToSaveSet %AddToSyncSet
%BMEBuilt %BuildIndicesAsync %BuildIndicesAsyncResponse %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 %OnDeleteFinally
%OnDetermineClass %OnOpenFinally %OnSaveFinally %Open
%OpenId %OriginalNamespace %PackageName %PhysicalAddress
%PurgeIndices %Reload %RemoveFromSaveSet %ResolveConcurrencyConflict
%RollBack %Save %SaveDirect %SaveIndices
%SerializeObject %SetModified %SortBegin %SortEnd
%SyncObjectIn %SyncTransport %UnlockExtent %UnlockId
%ValidateIndices %ValidateObject %ValidateTable AllDashboardSensorsClose
AllDashboardSensorsExecute AllDashboardSensorsFetch DeleteByClass Open


Properties

• property Alert as %String;
Boolean flag ("0" or "1") to indicate if System Monitor generates an alert on CriticalValue
• property CriticalValue as %String;
Value used to check for critical/alert status
• property Description as %String(MAXLEN=200);
Text description of the Sensor for documentation.
• property Item as %String(MAXLEN=500) [ InitialExpression = "-" ];
Some sensors may define multiple values or 'subitems', such disk space for a specific database. If the sensor is only a single value, then this property contains a "-" to identify as a single or base level sensor.
• property Name as %String(MAXLEN=100);
Name of the Sensor
• property Operator as %String [ InitialExpression = ">" ];
Logical operator used to compare Warning/Critial values. Default is ">", with option of "<".
• property ReadingInterval as %String;
Number of seconds between each reading This value is inherited by %SYS.Monitor.Control in all cases, but could be extended so sensors have induvidual reading delays
• relationship Readings as %SYS.Monitor.Reading [ Inverse = Sensor,Cardinality = children ];
• property Units as %String;
Description of units used, for display and documentation only.
• property WarningValue as %String;
Value used to check for warning status. Note that if WarningValue, CriticalValue, and AlertFlag are null for a specific Sensor.Item, then that Item will use the values of the base ("-") Sensor.

Methods

• classmethod AllDashboardSensorsClose(ByRef qHandle As %Binary) as %Status
• classmethod AllDashboardSensorsExecute(ByRef qHandle As %Binary) as %Status
• classmethod AllDashboardSensorsFetch(ByRef qHandle As %Binary, ByRef Row As %List, ByRef AtEnd As %Integer = 0) as %Status
• classmethod DeleteByClass(ClassName As %String) as %Status
Delete all Sensor and Readings associated with a ClassName (i.e. "Owner")
• classmethod Open(Sensor As %String, Item As %String = "", ByRef Status As %Status) as Sensor
Open an exisiting Sensor for editing Critical and Warning Values or other properties. 'Item' may be "" to open a top level Sensor. Setting Critical/Warning Values for a specific Item will override the Values from the top level.

Note that internal properties for 'Owner' and 'Function' should not be modified by users.

Queries

• query AllDashboardSensors()
Selects Name As %String, Item As %String, CriticalValue As %String, WarningValue As %String, Alert As %String, Operator As %String, Units As %String, Description As %String, ReadingInterval As %String, Namespace As %String
Loop through all registered Namespaces and return all registered Dashboard Sensors. If a Sensor has specific Items, do not include the top-level Sensor definition.
• query SensorIDs()
SQL Query :
SELECT ID FROM Sensor
WHERE Sensor.Item = '-'
A list of all top level Sensor IDs
• query SensorItems(Name As %String)
SQL Query :
SELECT Item FROM Sensor
WHERE Sensor.Name = :Name AND Sensor.Item != '-'
A list of all Sensor.Items for a given Sensor
• query SensorNames()
SQL Query :
SELECT Name FROM Sensor
WHERE Sensor.Item = '-'
A list of all top level Sensor Names

Indices

•index (SensorIndex on Name,Item) [IdKey,Unique];


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