Examples of TransactionException


Examples of org.hibernate.TransactionException

    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 status==Status.STATUS_ACTIVE;
    }
  }
View Full Code Here

Examples of org.hibernate.TransactionException

    else {
      try {
        getTransactionManager().getTransaction().registerSynchronization(sync);
      }
      catch (Exception e) {
        throw new TransactionException("could not register synchronization", e);
      }
    }
  }
View Full Code Here

Examples of org.hibernate.TransactionException

  public void setTimeout(int seconds) {
    try {
      ut.setTransactionTimeout(seconds);
    }
    catch (SystemException se) {
      throw new TransactionException("could not set transaction timeout", se);
    }
  }
View Full Code Here

Examples of org.hibernate.TransactionException

    log.debug("begin");
   
    boolean synchronization = jdbcContext.registerSynchronizationIfPossible();

    if ( !synchronization ) {
      throw new TransactionException("Could not register synchronization for container transaction");
    }

    begun = true;
   
    jdbcContext.afterTransactionBegin(this);
View Full Code Here

Examples of org.hibernate.TransactionException

  /**
   * {@inheritDoc}
   */
  public void commit() throws HibernateException {
    if (!begun) {
      throw new TransactionException("Transaction not successfully started");
    }

    log.debug("commit");

    boolean flush = !transactionContext.isFlushModeNever() &&
View Full Code Here

Examples of org.hibernate.TransactionException

  /**
   * {@inheritDoc}
   */
  public void rollback() throws HibernateException {
    if (!begun) {
      throw new TransactionException("Transaction not successfully started");
    }

    log.debug("rollback");

    try {
      getTransaction().setRollbackOnly();
    }
    catch (SystemException se) {
      log.error("Could not set transaction to rollback only", se);
      throw new TransactionException("Could not set transaction to rollback only", se);
    }

    begun = false;

  }
View Full Code Here

Examples of org.hibernate.TransactionException

    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 status==Status.STATUS_ACTIVE;
    }
  }
View Full Code Here

Examples of org.hibernate.TransactionException

    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);
    }
  }
View Full Code Here

Examples of org.huihoo.workflow.store.persistent.TransactionException

    {
      getStoreConnection().get().commit();
    }
    catch (SQLException sqlex)
    {
      throw new TransactionException(sqlex);
    }
  }
View Full Code Here

Examples of org.jboss.blacktie.jatmibroker.jab.TransactionException

      throws TransactionException {
    this.connection = connection;
    try {
      this.jabTransaction = new JABTransaction(session, timeout);
    } catch (Throwable e) {
      throw new TransactionException("Could not create the transaction: "
          + e.getMessage(), e);
    }
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.