public class HGUserAbortException
extends java.lang.RuntimeException
This exception is to be thrown by application code to force aborting the current transaction within a transaction closure.
When using the HGTransactionManager.transact
method, one supplies
a transaction closure, a Callable
instance that perform the transaction
work. However, the transact
will always attempt to commit the
transaction upon return from the user supplied Callable
. If the
application decides to abort the transaction without retrying it, it should throw
this exception instead of calling HGTransactionManager.abort
. The alternative
would be for the application to implement its own transaction retry loop, which is
longer and error prone.
Constructor and Description |
---|
HGUserAbortException() |