Universal Messaging 9.10 | Administration Guide | Universal Messaging Enterprise Manager | Administration Using Enterprise Manager | Scheduling | Universal Messaging Scheduling : Memory Triggers Example
 
Universal Messaging Scheduling : Memory Triggers Example

scheduler myMemory {
/*
Declare the MemoryManager task/trigger. Not really required to do
*/
declare MemoryManager mem;

/*
Just using the MemoryManager task / trigger and not the declared mem as an example.
*/
when (MemoryManager.freeMemory <10000000){
MemoryManager.flush(false);
}

/*
Now when the Free Memory on the realm drops below 1000000 bytes force the
realm to release ALL available memory
*/
when ( mem.freeMemory <1000000){
mem.flush(true);
}

/*
This is the same as the one above, except not using the declared name.
*/
when ( MemoryManager.freeMemory <1000000){
MemoryManager.flush(true);
}

/*
totalMemory available on the realm
*/
when ( MemoryManager.totalMemory <20000000 ){
Logger.report("Declared Memory too small for realm");
}

/*
Out Of Memory counter, increments whenever the realm handles an out of memory exception
*/
when ( MemoryManager.outOfMemory> 2){
Logger.report("Realm has run out of memory more then the threshold allowed");
}

}

Copyright © 2013-2019 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.