Developer Documentation Library > Interviewer - Server > Monitoring and tuning system performance > Load balancing interviewing engines > Global objects
 
Global objects
There are three global objects available to the load script that provide information that can be used to determine how heavy loaded the engine is: Engine, System, and Process.
All have a Refresh method; however, this is not normally required because the counters are automatically refreshed before the load script is run.
Engine object
The Engine object represents information about the interviews that are running or have run on the engine. It also represents limits or values that have been configured in the registry for the engine.
Properties
CachedProjectCount
As Long
The number of projects cached on the engine.
CachedProjectWeight
As Long
The CachedProjectWeight set in the registry. Can be used to weight the PercentLoaded value if the project is cached.
CompletesPerSec
As Long
The number of interviews that completed during the last second.
CompletesPerSecLimit
As Long
The limit of CompletesPerSec for the engine as specified in the registry. The default value is 100.
ConnectionLimit
As Long
The ConnectionLimit for the engine as specified in the registry. The default value is 1000.
CurrentInterviews
As Long
The current number of interviews running. The optional ProjectName parameter can be used to get the count for a specific project, otherwise the total count is returned.
CurrentInterviewers
As Long
The current number of interviewers running. The optional ProjectName parameter can be used to get the count for a specific project, otherwise the total count is returned.
ErrorsPerSec
As Long
The number of errors that have occured processing requests for interviews during the last second.
ErrorsPerSecLimit
As Long
The limit for ErrorPerSec for mrEngine as specified in the registry. The default value is 30.
MaxCompletesPerSec
As Long
The maximum number of interviews that completed during a second since the engine was started.
MaxErrorsPerSec
As Long
The maximum number of errors that have occured processing requests for interviews during a second since the engine started.
MaxNextsPerSec
As Long
The maximum number of requests for the next page of an interview during a second since the engine was started.
MaxRequestsPerSec
As Long
The maximum number of requests during a second since the engine was started.
MaxRestartsPerSec
As Long
The maximum number of interviews that were restarted during a second since the engine was started.
MaxStartsPerSec
As Long
The maximum number of start requests during a second since the engine was started.
MaxTimeoutsPerSec
As Long
The maximum number of interviews that timed out during a second since the engine was started.
NextsPerSec
As Long
The number of requests for the next page of an interview during the last second.
RequestsPerSec
As Long
The number of requests during the last second.
RequestsPerSecLimit
As Long
The limit of RequestsPerSec for mrEngine as specified in the registry. The default value is 250.
RestartsPerSec
As Long
The number of interviews that were restarted during the last second.
RestartsPerSecLimit
As Long
The limit of RestartsPerSec for mrEngine as specified in the registry. The default value is 50.
StartsPerSec
As Long
The number of requests to start an interview during the last second.
StartsPerSecLimit
As Long
The limit of StartsPerSec for mrEngine as specified in the registry. The default value is 100.
TimeoutsPerSec
As Long
The number of interviews that timed out during the last second.
TimeoutsPerSecLimit
As Long
The limit of TimeoutsPerSec for mrEngine as specified in the registry. The default value is 100.
TotalErrors
As Long
The number of errors that have occured processing requests for interviews.
TotalInterviews
As Long
The total number of interviews started since mrEngine was started.
TotalRestarts
As Long
The number of interviews that have been restarted since mrEngine was started.
TotalTimeouts
As Long
The number of interviews that timed out since the engine was started.
Methods
Refresh()
Update the counters (not normally required)
IsCachedProject(Name As String)
As Boolean
Returns True if the specified project is currently cached
System object
The System object represents memory information for the whole machine. Its values are based on the values returned by the GlobalMemoryStatusEx Win32 API function. For more information, see:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/memory/base/globalmemorystatusex.asp
Properties
MemoryLoad
As Long
The percentage of the physical memory in use. This is:
MEMORYSTATUSEX.MemoryLoad
TotalPhysical
As Long Physical RAM in system (kilobytes):
MEMORYSTATUSEX.ullTotalPhys /1024
TotalVirtual
As Long
The total virtual memory address space for the process (typically 2GB) (kilobytes):
MEMORYSTATUSEX.ullTotalVirtual / 1024
AvailablePhysical
As Long
Available (unused) physical RAM (kilobytes):
MEMORYSTATUSEX.ullAvailPhys / 1024
AvailableVirtual
As Long
Virtual memory address space available for the process (kilobytes):
MEMORYSTATUSEX.ullAvailVirtual /1024
PercentProcessorTime
As Long
Total % processor time across all CPUs for the system. This is the average value of last five raw values.
Methods
Refresh()
Calls GlobalMemoryStatusEx to update the counters.
Process object
The Process object represents memory information for the single engine process. Its values are based on the values returned by the GetProcessMemoryInfo Win32 API function. For more information, see:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/perfmon/base/getprocessmemoryinfo.asp
Properties
PeakMemoryUsage
As Long
Peak memory (working-set) usage (kilobytes):
PROCESS_MEMORY_COUNTERS.PeakWorkingSetSize / 1024
MemoryUsage
As Long
Current memory (working-set) usage (kilobytes):
PROCESS_MEMORY_COUNTERS.WorkingSetSize /1024
VirtualMemoryUsage
As Long
Current virtual memory (swap file) usage (kilobytes):
PROCESS_MEMORY_COUNTERS.PagefileUsage /1024
PeakVirtualMemoryUsage
As Long
Peak virtual memory (swap file) usage (kilobytes):
PROCESS_MEMORY_COUNTERS.PeakPagefileUsage / 1024
PercentProcessorTime
As Long
Total % processor time across all CPUs for the current process. This is the average value of last five raw values.
Methods
Refresh()
Calls GetProcessMemoryInfo again to update the counters.
See also
Load balancing interviewing engines