|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
com.xenonsoft.bridgetown.aop.transaction.TransactionException
The base exception for an AOP transaction failure that occurs during the Bridgetown IoC Framework. The is a unchecked exception because sometimes developers do not want to write boilerplate code to catch SQLExceptions, or more specific JTA exceptions for the those transaction across data sources that are XA aware.
The best practice is to wrap the JTA Exception inside a TransactionException and rethrow. Normally one will not log the exception because such errors will be pick up in the application server general log. The worse thing you can do is to catch exception, log them to verbose, across all the tiers in a multi-layer architecture.
| Constructor Summary | |
TransactionException()
Default constructor |
|
TransactionException(java.lang.String message)
Standard constructor |
|
TransactionException(java.lang.String message,
java.lang.Throwable cause)
Standard constructor |
|
TransactionException(java.lang.Throwable cause)
Standard constructor |
|
| Methods inherited from class java.lang.Throwable |
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public TransactionException()
public TransactionException(java.lang.String message)
message - the message to reportpublic TransactionException(java.lang.Throwable cause)
cause - the root cause
public TransactionException(java.lang.String message,
java.lang.Throwable cause)
message - the message to reportcause - the root cause
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||