com.sleepycat.je.rep
Class LockPreemptedException
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.rep.LockPreemptedException
- All Implemented Interfaces:
- Serializable
public class LockPreemptedException
- extends LockConflictException
Thrown when a lock has been "stolen", or preempted, from a transaction in a
replicated environment.
The Transaction
handle is invalidated as a
result of this exception.
Locks may be preempted in a JE HA environment on a Replica system when
the HA write operation needs a lock that an application reader transaction
or cursor holds. This exception is thrown by a reader transaction or cursor
method that is called after a lock has been preempted.
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.
- Since:
- 4.0
- See Also:
- Serialized Form
LockPreemptedException
public LockPreemptedException(Locker locker,
Throwable cause)
- For internal use only.
wrapSelf
public LockPreemptedException wrapSelf(String msg)
- For internal use only.
- Specified by:
wrapSelf
in class OperationFailureException
Copyright (c) 2004-2010 Oracle. All rights reserved.