Home > Class Reference > %SYS namespace > %SYSTEM.Config.SharedMemoryHeap

%SYSTEM.Config.SharedMemoryHeap

class %SYSTEM.Config.SharedMemoryHeap extends %SYSTEM.Help

The %SYSTEM.Config.SharedMemoryHeap class provides an interface to return amount of Shared Memory Heap used by InterSystems IRIS instance.
It also provides API to get available Shared Memory Heap and recommended Shared Memory Heap parameter for configuration.

Method Inventory

Parameters

parameter DOMAIN = %Utility;
Default Localization Domain

Methods

classmethod FreeCount() as %String [ Language = objectscript ]

Return amount of available Shared Memory Heap in InterSystems IRIS System.

This returns a string in total,pages,smt,genstrtab format.
total - total Shared Memory Heap available including pages,smt,genstrtab.
pages - total available Shared Memory Heap pages(in bytes).
smt - total available memory in SMT table.
genstrtab - total available memory in General String Table.

final classmethod GetUsageSummary() as %String [ Language = objectscript ]
Return the total SMH memory used, SMH pages allocated and configured SMH memory. It returns a string with following information, they are separated by ',' and all the units are in byte.:
Total SMH memory used.
Total SMH pages allocated.
Total SMH memory configured.
classmethod MaxCount() as %Integer [ Language = objectscript ]
Return amount (in bytes) of configured Shared Memory Heap in InterSystems IRIS including 5 MB reserved at Startup for Shadowing.
final classmethod RecommendedSize(NumberOfProcess As %Integer = 0) as %Integer [ Language = objectscript ]

Return recommended amount of Shared Memory Heap to be configured in kilobytes.
This does not include the memory reserved for Shadowing:
1 cpu 5MB, 2 cpus 8MB, + 2MB for others [based on $System.Util.NumberOfCPUs()]
NumberOfProcess is the number of maximum process you want to calculate on. Omit this parameter or zero will use value in ^|"%SYS"|SYS("LASTMAXPID").
The calculation is based on the current memory usage of the system.
Total current used memory + ReserveExtra + Lock Table Size * 1.5 + 1 MB if LineByLine Monitor is not running.
The ReserveExtra is number of CPU * 2 MB + 1MB.

classmethod UsageQueryClose(ByRef qHandle As %Binary) as %Status [ Language = objectscript ]
classmethod UsageQueryExecute(ByRef qHandle As %Binary, ConsumerID As %Integer = -1) as %Status [ Language = objectscript ]
classmethod UsageQueryFetch(ByRef qHandle As %Binary, ByRef Row As %List, ByRef AtEnd As %Integer = 0) as %Status [ Language = objectscript ]
classmethod WebListClose(ByRef qHandle As %Binary) as %Status [ Language = objectscript ]
classmethod WebListExecute(ByRef qHandle As %Binary) as %Status [ Language = objectscript ]
classmethod WebListFetch(ByRef qHandle As %Binary, ByRef Row As %List, ByRef AtEnd As %Integer = 0) as %Status [ Language = objectscript ]

Queries

query UsageQuery(ConsumerID As %Integer = -1)
Selects Description As %String, Allocated SMH/ST As %Integer, SMH/ST Available As %Integer, SMH/ST Used As %Integer, SMT Used As %Integer, GST Used As %Integer, All Used As %Integer
Return Usage of Shared Memory Heap for each Consumer.
query WebList()
Selects Description As %String, Allocated SMH/ST As %Integer, SMH/ST Available As %Integer, SMH/ST Used As %Integer, SMT Used As %Integer, GST Used As %Integer, All Used As %Integer
Return Usage of Shared Memory Heap for each Consumer.

Inherited Members

Inherited Methods