Examples of rollback()


Examples of javax.resource.spi.LocalTransaction.rollback()

            }
            if (local == null)
               throw new ResourceException("Unfinished local transaction but managed connection does not provide a local transaction. " + this);
            else
            {
               local.rollback();
               log.debug("Unfinished local transaction was rolled back." + this);
            }
         }
      }
View Full Code Here

Examples of javax.resource.spi.XATerminator.rollback()

        final Xid xid = new XidImple(new Uid());
        final Transaction t = SubordinationManager.getTransactionImporter().importTransaction(xid);
        final TestSynchronization sync = new TestSynchronization();
        t.registerSynchronization(sync);
        final XATerminator xaTerminator = SubordinationManager.getXATerminator();
        xaTerminator.rollback(xid);
        assertFalse(sync.isBeforeCompletionDone());
        assertTrue(sync.isAfterCompletionDone());
        assertEquals(javax.transaction.Status.STATUS_ROLLEDBACK, t.getStatus());
    }
View Full Code Here

Examples of javax.sql.rowset.JdbcRowSet.rollback()

        assertTrue(jrs.getAutoCommit());
        assertTrue(jrs.absolute(3));
        jrs.updateString(2, "update3");
        jrs.updateRow();
        jrs.rollback();

        // after rollback, resultset is closed
        assertNull(jrs.getStatement());
        try {
            jrs.getString(2);
View Full Code Here

Examples of javax.transaction.Transaction.rollback()

      {
         public void run()
         {
            try
            {
               t.rollback();
            }
            catch (Exception e)
            {
               exceptions.add(e);
            }
View Full Code Here

Examples of javax.transaction.TransactionManager.rollback()

      assertEquals("value2", cache1.get(fqn, "key2"));

      txm.begin();
      cache2.put(fqn, "key", "value");
      assertEquals("value", cache2.get(fqn, "key"));
      txm.rollback();

      assertEquals("value2", cache1.get(fqn, "key2"));
      n = cache2.getNode(fqn);
      CacheLoaderInvalidationTest.assertHasBeenInvalidated(n, "Should have been invalidated");
   }
View Full Code Here

Examples of javax.transaction.UserTransaction.rollback()

     }
     catch (Throwable t)
     {
       if(tx!=null)
         try {
           tx.rollback();
         } catch (SystemException e) {
           //
         }
       throw new RuntimeException("Failed to create database", t);
     }
View Full Code Here

Examples of javax.transaction.xa.XAResource.rollback()

          exception = true;
            throw new TransactionRuntimeException(e);           
        } finally {
            try {
                if (!delistSuccessful || test.rollbackAllways()|| test.exceptionOccurred()) {
                  xaResource.rollback(xid);
                }
                else if (commit) {
                  xaResource.commit(xid, true);
                }           
            } catch (Exception e) {
View Full Code Here

Examples of jdbm.RecordManager.rollback()



        // rollback transaction, should revert to previous state

        recman.rollback();



        // insert same 150000 byte record.
View Full Code Here

Examples of jodd.jtx.JtxTransaction.rollback()

      System.out.println("\n\n");
      System.out.println(StringUtil.repeat('-', 55) + " end");
      tx.commit();
    } catch (Throwable throwable) {
      throwable.printStackTrace();
      tx.rollback();
    }

    try {
      ReflectUtil.invokeDeclared(app, "destroy", new Class[] {MadvocConfig.class}, new Object[] {null});
    } catch (Exception ex) {
View Full Code Here

Examples of liquibase.Liquibase.rollback()

                    liquibase.update(new Contexts(contexts), new LabelExpression(labels), getOutputWriter());
                } else if ("rollback".equalsIgnoreCase(command)) {
                    if (commandParams == null || commandParams.size() == 0) {
                        throw new CommandLineParsingException("rollback requires a rollback tag");
                    }
                    liquibase.rollback(commandParams.iterator().next(), new Contexts(contexts), new LabelExpression(labels));
                } else if ("rollbackToDate".equalsIgnoreCase(command)) {
                    if (commandParams == null || commandParams.size() == 0) {
                        throw new CommandLineParsingException("rollback requires a rollback date");
                    }
                    liquibase.rollback(new ISODateFormat().parse(commandParams.iterator().next()), new Contexts(contexts), new LabelExpression(labels));
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.