[Mulgara-svn] r1353 - trunk/src/jar/resolver-spi/java/org/mulgara/resolver/spi
ronald at mulgara.org
ronald at mulgara.org
Thu Oct 23 13:12:12 UTC 2008
Author: ronald
Date: 2008-10-23 06:12:11 -0700 (Thu, 23 Oct 2008)
New Revision: 1353
Modified:
trunk/src/jar/resolver-spi/java/org/mulgara/resolver/spi/AbstractXAResource.java
Log:
Always chain underlying exception to new exceptions.
Modified: trunk/src/jar/resolver-spi/java/org/mulgara/resolver/spi/AbstractXAResource.java
===================================================================
--- trunk/src/jar/resolver-spi/java/org/mulgara/resolver/spi/AbstractXAResource.java 2008-10-23 13:12:05 UTC (rev 1352)
+++ trunk/src/jar/resolver-spi/java/org/mulgara/resolver/spi/AbstractXAResource.java 2008-10-23 13:12:11 UTC (rev 1353)
@@ -209,7 +209,7 @@
// inconsistent state.
// Make sure the exception is logged.
logger.fatal("Failed to commit resource in transaction " + formatXid(xid), th);
- throw new XAException(XAException.XAER_RMERR);
+ throw (XAException)new XAException(XAException.XAER_RMERR).initCause(th);
} finally {
if (clean) {
transactionCompleted(tx);
@@ -237,7 +237,7 @@
// inconsistent state.
// Make sure the exception is logged.
logger.fatal("Failed to rollback resource in transaction " + formatXid(xid), th);
- throw new XAException(XAException.XAER_RMERR);
+ throw (XAException)new XAException(XAException.XAER_RMERR).initCause(th);
} finally {
if (clean) {
transactionCompleted(tx);
@@ -263,7 +263,7 @@
} catch (Throwable th) {
logger.error("Failed to forget transaction " + formatXid(xid), th);
clean = false;
- throw new XAException(XAException.XAER_RMERR);
+ throw (XAException)new XAException(XAException.XAER_RMERR).initCause(th);
} finally {
if (clean) {
transactionCompleted(tx);
More information about the Mulgara-svn
mailing list