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

persistent class SYS.History.SysData extends %Persistent, %XML.Adaptor

Basic detail collection class of System Usage metrics for the Monitor History database. Properties represent metrics which get collected every few minutes by the %MONAPP Application Monitor process when the %Monitor.System.HistorySys class is "active".

Inventory

Parameters Properties Methods Queries Indices ForeignKeys Triggers
6 9 2 1


Summary

Properties
DB DateTime Length Sys ZDATE
ZTIME

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 Export
ExportDB Purge Sample Summary
XMLDTD XMLExport XMLExportToStream XMLExportToString
XMLNew XMLSchema XMLSchemaNamespace XMLSchemaType


Properties

• property DB as array of SYS.History.Database;
Database metrics
• property DateTime as %TimeStamp;
Time of sample
• property Length as %Integer;
Length of sample in seconds
• property Sys as SYS.History.SystemUsage;
System usage metrics
• property ZDATE as %Integer;
UTC date key
• property ZTIME as %Integer;
UTC time key

Methods

• classmethod Export(FileName As %String, Start As %TimeStamp, End As %TimeStamp) as %Status
Export SystemUsage data for a time range in CSV format. The default is all of the data currently in the SysData class.

The default FileName is HistorySys_config_date_time.csv in the MGR directory.
'Start' and 'End' times (if necessary) are in YYYY-MM-DD HH:MM:SS format.
• classmethod ExportDB(FileName As %String, Start As %TimeStamp, End As %TimeStamp, Database As %String) as %Status
Export Database data for a time range in CSV format. The default is all of the data currently in the SysData class.

The default 'FileName' is HistoryDB_config_date_time.csv in the MGR directory.
'Start' and 'End' times (if necessary) are in YYYY-MM-DD HH:MM:SS format.
The 'Database' argument can select (by name) a single database to export. Otherwise, data for all databases is exported and the database name is exported as a column.
• classmethod Purge(Keep As %Integer = 0) as %Integer
Purge SysData interval data, keeping the last 'Keep' days. This is typically called at the start of each day from the %Monitor.System.HistorySys class, using the current system default for 'Keep' (see the SetPurge() method). The 'Keep' argument allows you to over ride the system default (a value of "0" or "" uses the system default)

Returns the number of entries purged.
• classmethod Sample() as SYS.History.SysData
Instantiate the class and fetch current values for all metric properties.
• classmethod Summary(Day As %Integer = 0) as %Status
Collect summaries of the SysData metrics for a day into the Hourly/Daily database. This is typically done automatically by %Monitor.System.HistorySys at the beginning of each day (for the previous day), but could be called manually if there's a problem.

The 'Day' argument sets the end date of the collection, with the default of "0" being the start of today (i.e. $H+Day), which would collect everything for yesterday. A "-1" would collect the day before yesterday; a "1" would collect today (as much as there is).

Queries

• query DBDateList(Start As %TimeStamp = {$zdt(+$h, 3)}, End As %TimeStamp = {$zdt($h+1, 3)})
SQL Query :
SELECT DateTime,SysData_DB.* FROM SysData,SysData_DB
WHERE ((SysData_DB.SysData = SysData.ID) AND (DateTime >= :Start) AND (DateTime <= :End))
Full listing of the Database metrics for a day or range of date/times. Default is today.
• query DateList(Start As %TimeStamp = {$zdt(+$h, 3)}, End As %TimeStamp = {$zdt($h+1, 3)})
SQL Query :
SELECT * FROM SysData
WHERE (DateTime >= :Start AND DateTime <= :End)
Full listing of SystemUsage metrics for a day or range of date/times. Default is today.

Indices

•index (ZDTindex on ZDATE,ZTIME) [IdKey];


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