Example - changing the Canister safety limits
About this task
In Release 7.2 and earlier, the Canister safety limits were controlled by three settings for the Canister. These settings defined limits for:
- Maximum number of hits in a session
- Maximum total bytes in a session
- Maximum total time in seconds in a session
In Release 8.0 and later, these limits are managed through Canister
Safety Limits [BB]
, a Discover Standard
Event that accesses three Discover session
attributes.
Through Advanced Mode in the Event Manager, you can edit the JavaScriptâ„¢ definition of the Canister Safety Limits event. Below is the default definition.
// Canister Safety Limits [BB]
function PALI$E_SAFETY_LIMITS()
{
//Default: 2048 Hits
if ($S.NumberOfHits > 2048)
TLCloseSession.CloseForSafetyHits();
//Default: 5242880 Bytes (5MB)
if (($S.TotalREQBytes + $S.TotalRSPBytes) > 5242880)
TLCloseSession.CloseForSafetySize();
//Default: 3600 Seconds (60 minutes)
if ($S.TotalTime> 3600)
TLCloseSession.CloseForSafetyTime();
}
Procedure
Results
Costly Session - Too Long
Costly Session - Too Many Hits
Costly Session - Too Big
After you modified the Canister Safety Limit
event,
the above events continue to fire and cannot be disabled, which may
cause confusion for some users. However, you can clear the Display
in Portal
option for these events to limit user interaction
with them. You might also consider changing the description to include NOT_USED
or
similar, as well as adding them to a special event label.