com.sleepycat.je
Class LockNotGrantedException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
com.sleepycat.je.DatabaseException
com.sleepycat.je.OperationFailureException
com.sleepycat.je.LockConflictException
com.sleepycat.je.DeadlockException
com.sleepycat.je.LockNotGrantedException
- All Implemented Interfaces:
- Serializable
Deprecated. replaced by LockNotAvailableException
public class LockNotGrantedException
- extends DeadlockException
Thrown when a non-blocking operation fails to get a lock, and EnvironmentConfig.LOCK_OLD_LOCK_EXCEPTIONS
is set to true. Non-blocking
transactions are configured using TransactionConfig.setNoWait(boolean)
.
The Transaction
handle is invalidated as a result of this
exception.
For compatibility with JE 3.3 and earlier, LockNotGrantedException
is thrown instead of LockNotAvailableException
when EnvironmentConfig.LOCK_OLD_LOCK_EXCEPTIONS
is set to true. This
configuration parameter is false by default. See EnvironmentConfig.LOCK_OLD_LOCK_EXCEPTIONS
for information on the changes
that should be made to all applications that upgrade from JE 3.3 or
earlier.
Normally, applications should catch the base class LockConflictException
rather than catching one of its subclasses. All lock
conflicts are typically handled in the same way, which is normally to abort
and retry the transaction. See LockConflictException
for more
information.
- See Also:
- Serialized Form
LockNotGrantedException
public LockNotGrantedException(Locker locker,
String message)
- Deprecated.
- For internal use only.
wrapSelf
public OperationFailureException wrapSelf(String msg)
- Deprecated.
- For internal use only.
- Overrides:
wrapSelf
in class DeadlockException
Copyright (c) 2004-2012 Oracle. All rights reserved.