Package javax.transaction

Examples of javax.transaction.UserTransaction.commit()


        }

        super.access00();

        if (utx != null){
            utx.commit();
        }
        return ic.proceed();
    }
}
View Full Code Here


        }

        super.access00();

        if (utx != null) {
            utx.commit();
        }
    }
}
View Full Code Here

        try {
            if (!callOnlyTransaction) {
                TableManager tableManager = new TableManager(dbName);
                tableManager.deleteTable(TABLE);
            }
            utx.commit();
        } catch (Exception e) {
            utx.rollback();
            throw new TransactionException("Error during commit.", e);
        }
View Full Code Here

        UserTransaction utx = TransactionHelper.getUserTransaction();
        if (!callOnlyTransaction) {
            TableManager tableManager = new TableManager(dbName);
            tableManager.deleteTable(TABLE);
        }
        utx.commit();

    }

    /**
     * Calls userTransaction.begin(), inserts the table and calls userTransaction.commit().
View Full Code Here

        try {
            if (!callOnlyTransaction) {
                TableManager tableManager = new TableManager(dbName);
                tableManager.insertTable(TABLE);
            }
            utx.commit();
        } catch (Exception e) {
            utx.rollback();
            throw new TransactionException("Error during commit.", e);
        }
View Full Code Here

         MessageProducer p = s.createProducer(queue);
         Message m = s.createTextMessage("one");

         p.send(m);

         ut.commit();

         conn.close();

         ConnectionFactory cf = (ConnectionFactory)initialContext.lookup("ConnectionFactory");
         conn = cf.createConnection();
View Full Code Here

     */
    public void verifyBMT() throws IllegalStateException, SecurityException, HeuristicMixedException,
            HeuristicRollbackException, RollbackException, SystemException, NotSupportedException, NamingException {
        UserTransaction utx = TransactionHelper.getUserTransaction();
        utx.begin();
        utx.commit();
    }
}
View Full Code Here

            }

            checkInstance(eManager, EntityManagerTester.NAME);

            if (utx != null){
                utx.commit();
            }


        } else if (ic.getMethod().toString().contains("accessEntityManagerFactory")) {
View Full Code Here

        } catch (RollbackApplicationException e) {
            logger.debug("The bean threw an expected error during the execution {0}", e);
        }
        // tries to commit
        try {
            utx.commit();
            if (!canCommit) {
                fail("The transaction was marked as rolled back, the client cannot make the commit.");
            }
        } catch (Exception e) {
            logger.debug("The bean threw an expected error during the execution {0}", e);
View Full Code Here

        } catch (AppException e) {
            logger.debug("The bean threw an expected error during the execution {0}", e);
        }
        // tries to commit
        try {
            utx.commit();
        } catch (Exception e) {
            logger.debug("The bean threw an expected error during the execution {0}", e);
        }
        // verifies if the table was created in the DATABASE_1
        ExceptionHandleUtil.verifyTable(DATABASE_1, ItfContainerTransaction.TABLE);
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.