private boolean isTransactionInProgress(Transaction tx) throws SystemException { return JTAHelper.isTransactionInProgress(tx) && ! JTAHelper.isRollback( tx.getStatus() ); }
public boolean wasRolledBack() throws TransactionException { if (!begun) return false; final int status; try { status = transaction.getStatus(); } catch (SystemException se) { log.error("Could not determine transaction status", se); throw new TransactionException("Could not determine transaction status", se); } if (status==Status.STATUS_UNKNOWN) { throw new TransactionException("Could not determine transaction status"); } else { return JTAHelper.isRollback(status); } }
public boolean wasRolledBack() throws TransactionException { //if (!begun) return false; //if (commitFailed) return true; final int status; try { status = ut.getStatus(); } catch (SystemException se) { log.error("Could not determine transaction status", se); throw new TransactionException("Could not determine transaction status", se); } if (status==Status.STATUS_UNKNOWN) { throw new TransactionException("Could not determine transaction status"); } else { return JTAHelper.isRollback(status); } }
public boolean wasRolledBack() throws TransactionException { if (!begun) return false; if (commitFailed) return true; final int status; try { status = ut.getStatus(); } catch (SystemException se) { log.error("Could not determine transaction status", se); throw new TransactionException("Could not determine transaction status", se); } if (status==Status.STATUS_UNKNOWN) { throw new TransactionException("Could not determine transaction status"); } else { return JTAHelper.isRollback(status); } }
public boolean wasRolledBack() throws TransactionException { if (!begun) return false; final int status; try { status = getTransaction().getStatus(); } catch (SystemException se) { log.error("Could not determine transaction status", se); throw new TransactionException("Could not determine transaction status", se); } if (status==Status.STATUS_UNKNOWN) { throw new TransactionException("Could not determine transaction status"); } else { return JTAHelper.isRollback(status); } }
public void beforeCompletion() { log.trace("transaction before completion callback"); boolean flush; try { flush = !ctx.isFlushModeNever() && ctx.isFlushBeforeCompletionEnabled() && !JTAHelper.isRollback( transaction.getStatus() ); //actually, this last test is probably unnecessary, since //beforeCompletion() doesn't get called during rollback } catch (SystemException se) { log.error("could not determine transaction status", se); throw new TransactionException("could not determine transaction status in beforeCompletion()", se); } try { if (flush) { log.trace("automatically flushing session"); ctx.managedFlush(); } } finally { jdbcContext.beforeTransactionCompletion(hibernateTransaction); } }
private boolean isTransactionInProgress(Transaction tx) throws SystemException { return JTAHelper.isTransactionInProgress(tx) && ! JTAHelper.isRollback( tx.getStatus() ); }
( transaction == null || !JTAHelper.isRollback( transaction.getStatus() ) );
public void beforeCompletion() { log.trace("transaction before completion callback"); boolean flush; try { flush = !ctx.isFlushModeNever() && ctx.isFlushBeforeCompletionEnabled() && !JTAHelper.isRollback( transaction.getStatus() ); //actually, this last test is probably unnecessary, since //beforeCompletion() doesn't get called during rollback } catch (SystemException se) { log.error("could not determine transaction status", se); setRollbackOnly(); throw new TransactionException("could not determine transaction status in beforeCompletion()", se); } try { if (flush) { log.trace("automatically flushing session"); ctx.managedFlush(); } } catch (RuntimeException re) { setRollbackOnly(); throw re; } finally { jdbcContext.beforeTransactionCompletion(hibernateTransaction); } }
( transaction == null || !JTAHelper.isRollback( transaction.getStatus() ) );