public final class CriticalSectionUtil
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static void |
enterCriticalSection(CustomActionTriggerContext context,
CustomActionLogger logger,
java.lang.String lockName)
Gets the lock for the current service request.
|
static void |
enterCriticalSection(int srId,
java.lang.String lockName)
Gets the lock for the current service request.
|
static void |
enterNonSRCriticalSection(java.lang.String uniqueId,
java.lang.String lockName)
Gets the lock for a non service request critical section by using hte uniqueId and lockName
|
static void |
exitCriticalSection(CustomActionTriggerContext context,
CustomActionLogger logger)
Release all locks held by the SR at this time.
|
static void |
exitCriticalSection(int srId)
Removes the lock from the database for this specific service request
|
static void |
exitNonSRCriticalSection(java.lang.String uniqueId)
Release all locks held by the Unique ID at this time.
|
public static void exitCriticalSection(CustomActionTriggerContext context, CustomActionLogger logger) throws java.lang.Exception
context - - the CustomActionTriggerContextlogger - - the customActionLoggerjava.lang.Exceptionpublic static void enterCriticalSection(CustomActionTriggerContext context, CustomActionLogger logger, java.lang.String lockName) throws java.lang.Exception
context - - the customActionTriggerContextlogger - - the customActionLoggerlockName - - the lockNamejava.lang.Exception - when the lockName is null. Also when maximum wait time exceededpublic static void enterCriticalSection(int srId,
java.lang.String lockName)
throws java.lang.Exception
srId - - the service request idlockName - - the lockNamejava.lang.Exception - when the lockName is null. Also when maximum wait time exceededpublic static void exitCriticalSection(int srId)
throws java.lang.Exception
srId - - the service request idjava.lang.Exceptionpublic static void exitNonSRCriticalSection(java.lang.String uniqueId)
throws java.lang.Exception
uniqueId - - the unique Idjava.lang.Exceptionpublic static void enterNonSRCriticalSection(java.lang.String uniqueId,
java.lang.String lockName)
throws java.lang.Exception
uniqueId - - the uniqueIdlockName - - the lockNamejava.lang.Exception - when the lockName is null. Also when maximum wait time exceeded