/** * Sets the transaction timeout. */ @Override public boolean setTransactionTimeout(int seconds) throws XAException { long start = start(); try { boolean ok = _xaResource.setTransactionTimeout(seconds); if (log.isLoggable(Level.FINE)) log(start, "set-transaction-timeout(" + seconds + ")->" + ok); return ok; } catch (XAException e) { log.log(Level.FINE, e.toString(), e); throw e; } catch (RuntimeException e) { log.log(Level.FINE, e.toString(), e); throw e; } }
/** * Gets the transaction timeout. */ @Override public int getTransactionTimeout() throws XAException { long start = start(); try { int seconds = _xaResource.getTransactionTimeout(); if (log.isLoggable(Level.FINE)) log(start, "transaction-timeout()->" + seconds); return seconds; } catch (XAException e) { log.log(Level.FINE, e.toString(), e); throw e; } catch (RuntimeException e) { log.log(Level.FINE, e.toString(), e); throw e; } }
/** * Returns true if the underlying RM is the same. */ @Override public boolean isSameRM(XAResource resource) throws XAException { long start = start(); try { if (resource instanceof SpyXAResource) resource = ((SpyXAResource) resource).getXAResource(); boolean same = _xaResource.isSameRM(resource); if (log.isLoggable(Level.FINE)) log(start, "is-same-rm(resource=" + resource + ")->" + same); return same; } catch (XAException e) { log.log(Level.FINE, e.toString(), e); throw e; } catch (RuntimeException e) { log.log(Level.FINE, e.toString(), e); throw e; } }
/** * Commits the resource */ @Override public void commit(Xid xid, boolean onePhase) throws XAException { long start = start(); try { _xaResource.commit(xid, onePhase); if (log.isLoggable(Level.FINE)) log(start, "commit(xid=" + xid + (onePhase ? ",1P)" : ",2P)")); } catch (XAException e) { log(start, "exn-commit(" + xid + ") -> " + e); log.log(Level.FINE, e.toString(), e); throw e; } catch (RuntimeException e) { log(start, "exn-commit(" + xid + ") -> " + e); log.log(Level.FINE, e.toString(), e); throw e; } }
/** * Forgets the transaction */ @Override public void forget(Xid xid) throws XAException { long start = start(); try { _xaResource.forget(xid); if (log.isLoggable(Level.FINE)) log(start, "forget(xid=" + xid + ")"); } catch (XAException e) { log(start, "exn-force(" + xid + ") -> " + e); log.log(Level.FINE, e.toString(), e); throw e; } catch (RuntimeException e) { log(start, "exn-force(" + xid + ") -> " + e); log.log(Level.FINE, e.toString(), e); throw e; } }
/** * Rolls the resource back */ @Override public void rollback(Xid xid) throws XAException { long start = start(); try { _xaResource.rollback(xid); if (log.isLoggable(Level.FINE)) log(start, "rollback(xid=" + xid + ")"); } catch (XAException e) { log(start, "exn-rollback(xid) -> " + e); log.log(Level.FINE, e.toString(), e); throw e; } catch (RuntimeException e) { log(start, "exn-rollback(xid) -> " + e); log.log(Level.FINE, e.toString(), e); throw e; } }
/** * Rolls the resource back */ @Override public int prepare(Xid xid) throws XAException { long start = start(); try { int value = _xaResource.prepare(xid); if (log.isLoggable(Level.FINE)) log(start, "prepare(xid=" + xid + ")->" + value); return value; } catch (XAException e) { log(start, "exn-prepare(" + xid + ") -> " + e); log.log(Level.FINE, e.toString(), e); throw e; } catch (RuntimeException e) { log(start, "exn-prepare(" + xid + ") -> " + e); log.log(Level.FINE, e.toString(), e); throw e; } }
log(start, "exn-recover() " + e); log.fine(e.toString()); throw e; } catch (RuntimeException e) {
log.log(Level.FINE, e.toString(), e); log(start, "exn-end(" + xid + ") -> " + e);
log(start, "exn-start(" + xid + ") -> " + e); log.log(Level.FINE, e.toString(), e); throw e; } catch (RuntimeException e) {
XAHelper.printXAErrorCode(ex), ex); throw new com.arjuna.ats.arjuna.exceptions.FatalError(ex.toString(), ex);
XAHelper.printXAErrorCode(ex), ex); throw new com.arjuna.ats.arjuna.exceptions.FatalError(ex.toString(), ex);
XAHelper.printXAErrorCode(ex), ex); throw new com.arjuna.ats.arjuna.exceptions.FatalError(ex.toString(), ex);
throw new com.arjuna.ats.arjuna.exceptions.FatalError(ex.toString(), ex);
XAHelper.printXAErrorCode(ex), ex); throw new com.arjuna.ats.arjuna.exceptions.FatalError(ex.toString(), ex);
XAHelper.printXAErrorCode(ex), ex); throw new com.arjuna.ats.arjuna.exceptions.FatalError(ex.toString(), ex);
XAHelper.printXAErrorCode(ex), ex); throw new com.arjuna.ats.arjuna.exceptions.FatalError(ex.toString(), ex);