Package org.springframework.transaction

Examples of org.springframework.transaction.TransactionSystemException


        logger.debug("Retrieving JTA UserTransaction from JNDI location [" + userTransactionName + "]");
      }
      return (UserTransaction) getJndiTemplate().lookup(userTransactionName, UserTransaction.class);
    }
    catch (NamingException ex) {
      throw new TransactionSystemException(
          "JTA UserTransaction is not available at JNDI location [" + userTransactionName + "]", ex);
    }
  }
View Full Code Here


        logger.debug("Retrieving JTA TransactionManager from JNDI location [" + transactionManagerName + "]");
      }
      return (TransactionManager) getJndiTemplate().lookup(transactionManagerName, TransactionManager.class);
    }
    catch (NamingException ex) {
      throw new TransactionSystemException(
          "JTA TransactionManager is not available at JNDI location [" + transactionManagerName + "]", ex);
    }
  }
View Full Code Here

      Class registryClass = ClassUtils.forName(TRANSACTION_SYNCHRONIZATION_REGISTRY_CLASS_NAME,
          JtaTransactionManager.class.getClassLoader());
      return getJndiTemplate().lookup(registryName, registryClass);
    }
    catch (ClassNotFoundException ex) {
      throw new TransactionSystemException(
          "JTA 1.1 [" + TRANSACTION_SYNCHRONIZATION_REGISTRY_CLASS_NAME + "] not available");
    }
    catch (NamingException ex) {
      throw new TransactionSystemException(
          "JTA TransactionSynchronizationRegistry is not available at JNDI location [" + registryName + "]", ex);
    }
  }
View Full Code Here

    JtaTransactionObject txObject = (JtaTransactionObject) transaction;
    try {
      return (txObject.getUserTransaction().getStatus() != Status.STATUS_NO_TRANSACTION);
    }
    catch (SystemException ex) {
      throw new TransactionSystemException("JTA failure on getStatus", ex);
    }
  }
View Full Code Here

    JtaTransactionObject txObject = (JtaTransactionObject) transaction;
    try {
      return doJtaSuspend(txObject);
    }
    catch (SystemException ex) {
      throw new TransactionSystemException("JTA failure on suspend", ex);
    }
  }
View Full Code Here

    }
    catch (InvalidTransactionException ex) {
      throw new IllegalTransactionStateException("Tried to resume invalid JTA transaction", ex);
    }
    catch (IllegalStateException ex) {
      throw new TransactionSystemException("Unexpected internal transaction state", ex);
    }
    catch (SystemException ex) {
      throw new TransactionSystemException("JTA failure on resume", ex);
    }
  }
View Full Code Here

    }
    catch (HeuristicRollbackException ex) {
      throw new HeuristicCompletionException(HeuristicCompletionException.STATE_ROLLED_BACK, ex);
    }
    catch (IllegalStateException ex) {
      throw new TransactionSystemException("Unexpected internal transaction state", ex);
    }
    catch (SystemException ex) {
      throw new TransactionSystemException("JTA failure on commit", ex);
    }
  }
View Full Code Here

            if (logger.isDebugEnabled()) {
              logger.debug("Rollback failure with transaction already marked as rolled back: " + ex);
            }
          }
          else {
            throw new TransactionSystemException("Unexpected internal transaction state", ex);
          }
        }
      }
    }
    catch (SystemException ex) {
      throw new TransactionSystemException("JTA failure on rollback", ex);
    }
  }
View Full Code Here

      if (jtaStatus != Status.STATUS_NO_TRANSACTION && jtaStatus != Status.STATUS_ROLLEDBACK) {
        txObject.getUserTransaction().setRollbackOnly();
      }
    }
    catch (IllegalStateException ex) {
      throw new TransactionSystemException("Unexpected internal transaction state", ex);
    }
    catch (SystemException ex) {
      throw new TransactionSystemException("JTA failure on setRollbackOnly", ex);
    }
  }
View Full Code Here

          "transaction - processing Spring after-completion callbacks with outcome status 'unknown'" +
          "Original exception: " + ex);
      invokeAfterCompletion(synchronizations, TransactionSynchronization.STATUS_UNKNOWN);
    }
    catch (SystemException ex) {
      throw new TransactionSystemException("JTA failure on registerSynchronization", ex);
    }
  }
View Full Code Here

TOP

Related Classes of org.springframework.transaction.TransactionSystemException

Copyright © 2018 www.massapicom. 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.