case XAException.XA_HEURMIX: HeuristicMixedException hmex = new HeuristicMixedException(); hmex.initCause(xaex); throw hmex; case XAException.XAER_INVAL:
statusRef.set(Status.STATUS_UNKNOWN); final HeuristicMixedException e = Log.log.peerHeuristicMixedException(); e.initCause(RemoteExceptionCause.readFromStream(is)); throw e; } else if (id == Protocol.P_UT_HRE_EXC) {
transactionCoordinator.forgetQuietly(transactionXid); HeuristicMixedException hmex = new HeuristicMixedException(); hmex.initCause(xaEx); throw hmex; case XAException.XAER_RMERR:
private static void rethrowAsJtaHeuristicMixedException(String msg, Throwable cause) throws javax.transaction.HeuristicMixedException { javax.transaction.HeuristicMixedException ret = new javax.transaction.HeuristicMixedException( msg); ret.initCause(cause); throw ret; }
private void rollbackResources(List<TransactionBranch> rms, boolean everRb) throws HeuristicMixedException, SystemException { RollbackTask rollbackTask = new RollbackTask(xid, rms, logMark, txManager); synchronized (this) { status = Status.STATUS_ROLLING_BACK; } rollbackTask.run(); synchronized (this) { status = rollbackTask.getStatus(); } XAException cause = rollbackTask.getCause(); boolean everRolledback = everRb || rollbackTask.isEverRolledBack(); if (cause != null) { if (cause.errorCode == XAException.XA_HEURCOM && everRolledback) { throw (HeuristicMixedException) new HeuristicMixedException("HeuristicMixed error during commit/rolling back").initCause(cause); } else if (cause.errorCode == XAException.XA_HEURMIX) { throw (HeuristicMixedException) new HeuristicMixedException("HeuristicMixed error during commit/rolling back").initCause(cause); } else { throw (SystemException) new SystemException("System Error during commit/rolling back").initCause(cause); } } }
private void commitResources(List<TransactionBranch> rms) throws HeuristicRollbackException, HeuristicMixedException, SystemException { CommitTask commitTask = new CommitTask(xid, rms, logMark, txManager); synchronized (this) { status = Status.STATUS_COMMITTING; } commitTask.run(); synchronized (this) { status = commitTask.getStatus(); } XAException cause = commitTask.getCause(); boolean evercommit = commitTask.isEvercommit(); if (cause != null) { if (cause.errorCode == XAException.XA_HEURRB && !evercommit) { throw (HeuristicRollbackException) new HeuristicRollbackException("Error during two phase commit").initCause(cause); } else if (cause.errorCode == XAException.XA_HEURRB && evercommit) { throw (HeuristicMixedException) new HeuristicMixedException("Error during two phase commit").initCause(cause); } else if (cause.errorCode == XAException.XA_HEURMIX) { throw (HeuristicMixedException) new HeuristicMixedException("Error during two phase commit").initCause(cause); } else { throw (SystemException) new SystemException("Error during two phase commit").initCause(cause); } } }
exception.initCause(cause); throw exception;
case XAException.XA_HEURMIX: HeuristicMixedException hmex = new HeuristicMixedException(); hmex.initCause(xaex); throw hmex; case XAException.XAER_INVAL:
throw (HeuristicRollbackException) new HeuristicRollbackException("Error during two phase commit").initCause(cause); } else if (cause.errorCode == XAException.XA_HEURRB && evercommit) { throw (HeuristicMixedException) new HeuristicMixedException("Error during two phase commit").initCause(cause); } else if (cause.errorCode == XAException.XA_HEURMIX) { throw (HeuristicMixedException) new HeuristicMixedException("Error during two phase commit").initCause(cause); } else { throw (SystemException) new SystemException("Error during two phase commit").initCause(cause);
this.transactionListenerList.onCommitHeuristicMixed(xid); HeuristicMixedException hmex = new HeuristicMixedException(); hmex.initCause(xaex); throw hmex; case XAException.XA_HEURCOM:
} else { if (cause.errorCode == XAException.XA_HEURCOM && everRolledback) { throw (HeuristicMixedException) new HeuristicMixedException("HeuristicMixed error during commit/rolling back").initCause(cause); } else if (cause.errorCode == XAException.XA_HEURMIX) { throw (HeuristicMixedException) new HeuristicMixedException("HeuristicMixed error during commit/rolling back").initCause(cause); } else { throw (SystemException) new SystemException("System Error during commit/rolling back").initCause(cause);
this.transactionListenerList.onCommitHeuristicMixed(xid); HeuristicMixedException hmex = new HeuristicMixedException(); hmex.initCause(xaex); throw hmex; case XAException.XA_HEURCOM:
} else { if (cause.errorCode == XAException.XA_HEURCOM && everRolledback) { throw (HeuristicMixedException) new HeuristicMixedException("HeuristicMixed error during commit/rolling back").initCause(cause); } else if (cause.errorCode == XAException.XA_HEURMIX) { throw (HeuristicMixedException) new HeuristicMixedException("HeuristicMixed error during commit/rolling back").initCause(cause); } else { throw (SystemException) new SystemException("System Error during commit/rolling back").initCause(cause);
this.transactionListenerList.onCommitHeuristicMixed(xid); HeuristicMixedException hmex = new HeuristicMixedException(); hmex.initCause(xaex); throw hmex; case XAException.XA_HEURCOM:
cause = e; manager.getCommitter().forget(manager.getBranchId()); throw (HeuristicMixedException) new HeuristicMixedException("Error during one-phase commit").initCause(e); } else if (e.errorCode == XAException.XA_HEURCOM) { throw (HeuristicRollbackException) new HeuristicRollbackException("Error during two phase commit").initCause(cause); } else if (cause.errorCode == XAException.XA_HEURMIX) { throw (HeuristicMixedException) new HeuristicMixedException("Error during two phase commit").initCause(cause); } else if (cause.errorCode == XAException.XA_RBROLLBACK || cause.errorCode == XAException.XAER_RMERR
cause = e; manager.getCommitter().forget(manager.getBranchId()); throw (HeuristicMixedException) new HeuristicMixedException("Error during one-phase commit").initCause(e); } else if (e.errorCode == XAException.XA_HEURCOM) { throw (HeuristicRollbackException) new HeuristicRollbackException("Error during two phase commit").initCause(cause); } else if (cause.errorCode == XAException.XA_HEURMIX) { throw (HeuristicMixedException) new HeuristicMixedException("Error during two phase commit").initCause(cause); } else if (cause.errorCode == XAException.XA_RBROLLBACK || cause.errorCode == XAException.XAER_RMERR
cause = e; manager.getCommitter().forget(manager.getBranchId()); throw (HeuristicMixedException) new HeuristicMixedException("Error during one-phase commit").initCause(e); } else if (e.errorCode == XAException.XA_HEURCOM) { throw (HeuristicRollbackException) new HeuristicRollbackException("Error during two phase commit").initCause(cause); } else if (cause.errorCode == XAException.XA_HEURMIX) { throw (HeuristicMixedException) new HeuristicMixedException("Error during two phase commit").initCause(cause); } else if (cause.errorCode == XAException.XA_RBROLLBACK || cause.errorCode == XAException.XAER_RMERR
hme.initCause(hhe.getCause()); //Set the cause to be the cause of the HeuristicHazardException if (tc.isEntryEnabled()) Tr.exit(tc, "commit", hme);
transactionCoordinator.forgetQuietly(transactionXid); HeuristicMixedException hmex = new HeuristicMixedException(); hmex.initCause(xaEx); throw hmex; case XAException.XAER_RMERR: