Package li.earth.urchin.twic.tx

Examples of li.earth.urchin.twic.tx.TransactionStatus


    }
  }
 
  private void endTransaction(boolean success, String requestURI) throws ServletException {
    try {
      TransactionStatus status = TransactionStatus.byCode(tx.getStatus());
      if (success && status.isCommittable()) {
        logger.debug("committing transaction for {}", requestURI);
        tx.commit();
      }
      else if (status.isRollbackable()) {
        logger.debug("rolling back {} transaction for {}", status.getAdjective(), requestURI);
        tx.rollback();
      }
      else {
        logger.warn("unable to either commit or roll back {} transaction for {}", status.getAdjective(), requestURI);
      }
    }
    catch (Exception e) {
      String message = "exception ending transaction for " + requestURI;
      logger.warn(message, e);
View Full Code Here

TOP

Related Classes of li.earth.urchin.twic.tx.TransactionStatus

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.