SYS.BackgroundIntegrity
persistent class SYS.BackgroundIntegrity extends %SYS.BackgroundTask
SQL Table Name: SYS.BackgroundIntegrity
Class to start, monitor, and control integrity check jobs running in the background. Used internally by the ^Integrity utility and leverages the %SYS.BackgroundTask framework.To start an integrity check background task,
set oref=##class(SYS.BackgroundIntegrity).Start(.dirgloarray, maxproc, partialcheck)
The dirgloarray argument contains nodes formatted as follows:
dirgloarray("/database/directory/")=$listbuild("globals","to","check")The subscript is the database directory, and the value is a list of globals to check for that database. If a global list is empty (""), then we check all globals for that database. If this array contains no subnodes, then we check all databases and all globals.
To view progress and status in the terminal,
do oref.CHUIMonitor()
Property Inventory
Method Inventory
Parameters
parameter CANCELDISPOSITION = -1;
The cancel disposition enables direct termination of a running integrity check.
See %SYS.BackgroundTask for further details.
parameter PAUSEDISPOSITION = 1;
The pause disposition enables pause of a running integrity check via polling.
See %SYS.BackgroundTask for further details.
Properties
property DatabaseList as %List;
List of database directories to check.
If empty, no databases were specified, and the task checks all databases.
Property methods: DatabaseListGet(), DatabaseListGetStored(), DatabaseListIsValid(), DatabaseListLogicalToOdbc(), DatabaseListOdbcToLogical(), DatabaseListSet()
property ErrorCount as %Integer [ Calculated ];
A count of errors detected so far, updated periodically for the progress display.
Note, count doesn't include every error found in a given global; it's the number
of globals that have errors, plus other errors that can occur at the meta-structure
level, such as in map blocks.
Property methods: ErrorCountCompute(), ErrorCountDisplayToLogical(), ErrorCountGet(), ErrorCountIsValid(), ErrorCountLogicalToDisplay(), ErrorCountNormalize(), ErrorCountSQLCompute()
property GlobalsChecked as %Integer [ Calculated ];
A count of globals checked so far, updated periodically for the progress display.
Property methods: GlobalsCheckedCompute(), GlobalsCheckedDisplayToLogical(), GlobalsCheckedGet(), GlobalsCheckedIsValid(), GlobalsCheckedLogicalToDisplay(), GlobalsCheckedNormalize(), GlobalsCheckedSQLCompute()
property ListOfGlobalLists as %List;
Lists of globals to check for each database.
The nth list of globals corresponds to the nth database in the DatabaseList
property. If list n is empty, the task checks all globals for database n.
If this property is empty, then so is DatabaseList (and vice versa), and
the task checks all globals in all databases.
Property methods: ListOfGlobalListsGet(), ListOfGlobalListsGetStored(), ListOfGlobalListsIsValid(), ListOfGlobalListsLogicalToOdbc(), ListOfGlobalListsOdbcToLogical(), ListOfGlobalListsSet()
property MaxProcesses as %Integer;
Maximum number of integrity check jobs that can run concurrently for this check.
Property methods: MaxProcessesDisplayToLogical(), MaxProcessesGet(), MaxProcessesGetStored(), MaxProcessesIsValid(), MaxProcessesLogicalToDisplay(), MaxProcessesNormalize(), MaxProcessesSet()
property PartialCheck as %Integer;
If this flag is set, only check the pointer structure of globals, not data blocks.
Otherwise, we do a full check on everything from pointers to data blocks.
Property methods: PartialCheckDisplayToLogical(), PartialCheckGet(), PartialCheckGetStored(), PartialCheckIsValid(), PartialCheckLogicalToDisplay(), PartialCheckNormalize(), PartialCheckSet()
Methods
method GetDatabaseGlobalArray(ByRef dirgloarray) as %Status
Composes an array in the original input format (see class description)
from the saved DatabaseList and ListOfGlobalList properties
and passes it back by reference in dirgloarray.
method GetOutputGlobal() as %String
Returns the name of the output global as a string. The global lives in the %SYS
database and is subscripted by the class object's %Id().
Queries
query ListIntegrityTasks()
SQL Query:
SELECT %ID, StartTime, RunningState, HasEnded, FinalStatus, DatabaseList, ListOfGlobalLists, MaxProcesses, PartialCheck, PID FROM SYS.BackgroundIntegrity
SELECT %ID, StartTime, RunningState, HasEnded, FinalStatus, DatabaseList, ListOfGlobalLists, MaxProcesses, PartialCheck, PID FROM SYS.BackgroundIntegrity
Lists all saved integrity check background tasks.
Inherited Members
Inherited Properties
- CancelIsAvailable
- Class
- DisplayType
- FinalStatus
- HasEnded
- Namespace
- PID
- PauseIsAvailable
- ProgressCurrent
- ProgressTotal
- ProgressUnits
- Request
- ResumeIsAvailable
- RunningState
- StartTime
Inherited 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()
- %InitExtentData()
- %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()
- Cancel()
- Pause()
- Resume()
- Start()
Storage
Gray indicates storage defined by superclasses.
Storage Model: Storage (%SYS.BackgroundTask)
^%SYS.BackgroundTaskD(ID) |
= | %%CLASSNAME
StartTime
Namespace
FinalStatus
PID
MemIdx
Version
JobNum
JobID
ExternalStateStored
|
Storage Model: Storage (SYS.BackgroundIntegrity)
^%SYS.BackgroundTaskD(ID,"BackgroundIntegrity") |
= | DatabaseList
ListOfGlobalLists
MaxProcesses
PartialCheck
|