public class TransactionException extends RuntimeException
All operations that occur within a transaction should be wrapped in a try-catch block so that transaction exceptions can be caught and the transaction can be properly aborted.
try {
concourse.stage();
concourse.get("foo", 1);
concourse.add("foo", "bar", 1);
concourse.commit();
}
catch (TransactionException e) {
concourse.abort();
}
Please note that this and all descendant exceptions are unchecked for backwards compatibility, but they may be changed to be checked in a future API breaking release.
| Constructor and Description |
|---|
TransactionException() |
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString