bool ComObjectsProfilerStart(ComObjectsProfilerStartArg tArg)
tArg. Operation execution parameters.
The ComObjectsProfilerStart operation enables memory leaks detection.
After executing the operation, object starts and their interaction are monitored and registered on BI server. It will be checked if there are cases when, for some reason, objects cannot be loaded from memory after their use. A memory leaks detection log will be created. If memory leaks detection has been started before, setting the tArg.ResetObjects field to True allows for resetting the created leaks detection log.
The further call of the ComObjectsProfilerClean operation allows for clearing the records with correct object work from the log and keeping only the records corresponding to unreleased objects.
The call of the ComObjectsProfilerFinish operation allows for disabling memory leaks detection and saving the generated log to file.
The ComObjectsProfilerStart operation results in the logical true if memory leaks detection is successfully enabled.
Below is the example of enabling memory leaks detection.
{
"ComObjectsProfilerStart" :
{
"tArg" :
{
"ResetObjects" : "true"
}
}
}
{
"ComObjectsProfilerStartResult" : "0"
}
public static bool ComObjectsProfilerStart()
{
var somClient = new SomPortTypeClient(); //Proxy object for operation execution
//Operation execution parameters
var tStart = new ComObjectsProfilerStart()
{
tArg = new ComObjectsProfilerStartArg()
{
ResetObjects = true
}
};
// Enable memory leaks detection
var result = somClient.ComObjectsProfilerStart(tStart);
return result;
}
See also: