Package org.hornetq.api.core.client

Examples of org.hornetq.api.core.client.ClientSession.rollback()


         boolean redelivered = message.getDeliveryCount() > 1;

         if (count % 2 == 0 && !redelivered)
         {
            session.rollback();
            rollbacked++;
         }
         else
         {
            session.commit();
View Full Code Here


         boolean redelivered = message.getDeliveryCount() > 1;

         if (count % 2 == 0 && !redelivered)
         {
            session.rollback();
            rollbacked++;
         }
         else
         {
            session.commit();
View Full Code Here

   {
      Xid xid = newXID();
      ClientSession session = sessionFactory.createSession(true, false, false);
      session.start(xid, XAResource.TMNOFLAGS);
      session.end(xid, XAResource.TMSUCCESS);
      session.rollback(xid);

      session.close();

      messagingService.stop();
View Full Code Here

      xid = newXID();
      session = sessionFactory.createSession(true, false, false);
      session.start(xid, XAResource.TMNOFLAGS);
      session.end(xid, XAResource.TMSUCCESS);
      session.rollback(xid);

      xid = newXID();
      session.start(xid, XAResource.TMNOFLAGS);
      session.end(xid, XAResource.TMSUCCESS);
      session.prepare(xid);
View Full Code Here

      xid = newXID();
      session = sessionFactory.createSession(true, false, false);
      session.start(xid, XAResource.TMNOFLAGS);
      session.end(xid, XAResource.TMSUCCESS);
      session.prepare(xid);
      session.rollback(xid);

      session.close();

      messagingService.start();
View Full Code Here

      xid = newXID();
      session = sessionFactory.createSession(true, false, false);
      session.start(xid, XAResource.TMNOFLAGS);
      session.end(xid, XAResource.TMSUCCESS);
      session.rollback(xid);

      session.close();

      messagingService.stop();
      messagingService.start();
View Full Code Here

   {
      Xid xid = newXID();
      ClientSession session = sessionFactory.createSession(true, false, false);
      session.start(xid, XAResource.TMNOFLAGS);
      session.end(xid, XAResource.TMFAIL);
      session.rollback(xid);

      session.close();

   }
View Full Code Here

         Assert.assertNotNull(m);
         m.acknowledge();
         m = cc.receive(5000);
         Assert.assertNotNull(m);
         m.acknowledge();
         clientSession.rollback();
         Assert.assertEquals(10, q.getMessageCount());
         clientSession.close();
         sendSession.close();
      }
      finally
View Full Code Here

               Xid[] xids = session.recover(XAResource.TMSTARTRSCAN);
               Assert.assertEquals(1, xids.length);
               Assert.assertEquals(xid, xids[0]);

               session.rollback(xid);
               producer = session.createProducer(ADDRESS);
               xid = newXID();
               session.start(xid, XAResource.TMNOFLAGS);
            }
            else
View Full Code Here

               xid = newXID();
               session.start(xid, XAResource.TMNOFLAGS);
            }
            else
            {
               session.rollback();
            }

            validateNoFilesOnLargeDir();
         }
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.