Package org.jboss.test.messaging.core

Examples of org.jboss.test.messaging.core.SimpleCondition


       //condition1

       queues[0] = new MessagingQueue(1, "sub1", channelIDManager.getID(), ms, pm, false, -1, null, false);
       queues[0].activate();
       boolean added = office1.addBinding(new Binding(new SimpleCondition("condition1"), queues[0], false), false);
       assertTrue(added);

       queues[1] = new MessagingQueue(1, "sub2", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queues[1].activate();
       added = office1.addBinding(new Binding(new SimpleCondition("condition1"), queues[1], false), false);
       assertTrue(added);

       queues[2] = new MessagingQueue(2, "sub3", channelIDManager.getID(), ms, pm, false, -1, null, false);
       queues[2].activate();
       added = office2.addBinding(new Binding(new SimpleCondition("condition1"), queues[2], false), false);
       assertTrue(added);

       queues[3] = new MessagingQueue(2, "sub4", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queues[3].activate();
       added = office2.addBinding(new Binding(new SimpleCondition("condition1"), queues[3], false), false);
       assertTrue(added);

       queues[4] = new MessagingQueue(2, "sub5", channelIDManager.getID(), ms, pm, true, -1, null, false);
       queues[4].activate();
       added = office2.addBinding(new Binding(new SimpleCondition("condition1"), queues[4], false), false);
       assertTrue(added);

       queues[5] = new MessagingQueue(1, "sub6", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queues[5].activate();
       added = office1.addBinding(new Binding(new SimpleCondition("condition1"), queues[5], false), false);
       assertTrue(added);

       queues[6] = new MessagingQueue(1, "sub7", channelIDManager.getID(), ms, pm, true, -1, null, false);
       queues[6].activate();
       added = office1.addBinding(new Binding(new SimpleCondition("condition1"), queues[6], false), false);
       assertTrue(added);

       queues[7] = new MessagingQueue(1, "sub8", channelIDManager.getID(), ms, pm, true, -1, null, true);
       queues[7].activate();
       added = office1.addBinding(new Binding(new SimpleCondition("condition1"), queues[7], false), false);
       assertTrue(added);

       //condition2


       queues[8] = new MessagingQueue(1, "sub9", channelIDManager.getID(), ms, pm, false, -1, null, false);
       queues[8].activate();
       added = office1.addBinding(new Binding(new SimpleCondition("condition2"), queues[8], false), false);
       assertTrue(added);

       queues[9] = new MessagingQueue(1, "sub10", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queues[9].activate();
       added = office1.addBinding(new Binding(new SimpleCondition("condition2"), queues[9], false), false);
       assertTrue(added);

       queues[10] = new MessagingQueue(2, "sub11", channelIDManager.getID(), ms, pm, false, -1, null, false);
       queues[10].activate();
       added = office2.addBinding(new Binding(new SimpleCondition("condition2"), queues[10], false), false);
       assertTrue(added);

       queues[11] = new MessagingQueue(2, "sub12", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queues[11].activate();
       added = office2.addBinding(new Binding(new SimpleCondition("condition2"), queues[11], false), false);
       assertTrue(added);

       queues[12] = new MessagingQueue(2, "sub13", channelIDManager.getID(), ms, pm, true, -1, null, false);
       queues[12].activate();
       added = office2.addBinding(new Binding(new SimpleCondition("condition2"), queues[12], false), false);
       assertTrue(added);

       queues[13] = new MessagingQueue(1, "sub14", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queues[13].activate();
       added = office1.addBinding(new Binding(new SimpleCondition("condition2"), queues[13], false), false);
       assertTrue(added);

       queues[14] = new MessagingQueue(1, "sub15", channelIDManager.getID(), ms, pm, true, -1, null, false);
       queues[14].activate();
       added = office1.addBinding(new Binding(new SimpleCondition("condition2"), queues[14], false), false);
       assertTrue(added);

       queues[15] = new MessagingQueue(1, "sub16", channelIDManager.getID(), ms, pm, true, -1, null, true);
       queues[15].activate();
       added = office1.addBinding(new Binding(new SimpleCondition("condition2"), queues[15], false), false);
       assertTrue(added);

       SimpleReceiver[] receivers = new SimpleReceiver[16];

       for (int i = 0; i < 16; i++)
       {
         receivers[i] = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
         queues[i].getLocalDistributor().add(receivers[i]);
       }

       Message msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);     
       MessageReference ref = ms.reference(msg);        

       RouteResult routed = office1.route(ref, new SimpleCondition("condition1"), null);        
       assertTrue(routed.getResult());

       //Messages are sent asych so may take some finite time to arrive
       Thread.sleep(3000);

       //Durable queues on remote node should never get the message - neither should non clustered ones

       for (int i = 0; i < 16; i++)
       {
         if (i >= 8 || (queues[i].getNodeID() == 2 && queues[i].isRecoverable())
             || (queues[i].getNodeID() == 2 && !queues[i].isClustered()))
         {
           this.checkNotGetsMessage(queues[i], receivers[i]);
         }
         else
         {
           //Should get the message
           this.checkGetsMessage(queues[i], receivers[i], msg);
         }
       }

       //Now route to condition2

       msg = CoreMessageFactory.createCoreMessage(2, persistentMessage, null);;     
       ref = ms.reference(msg);        

       routed = office2.route(ref, new SimpleCondition("condition2"), null);        
       assertTrue(routed.getResult());
       //Messages are sent asych so may take some finite time to arrive
       Thread.sleep(3000);

       for (int i = 0; i < 16; i++)
View Full Code Here


       //queue1

       Queue queue0 = new MessagingQueue(1, "myqueue1", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queue0.activate();
       boolean added = office1.addBinding(new Binding(new SimpleCondition("myqueue1"), queue0, false), false);
       assertTrue(added);

       Queue queue1 = new MessagingQueue(2, "myqueue1", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queue1.activate();
       added = office2.addBinding(new Binding(new SimpleCondition("myqueue1"), queue1, false), false);
       assertTrue(added);


       //queue2

       Queue queue2 = new MessagingQueue(1, "myqueue2", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queue2.activate();
       added = office1.addBinding(new Binding(new SimpleCondition("myqueue2"), queue2, false), false);
       assertTrue(added);

       Queue queue3 = new MessagingQueue(2, "myqueue2", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queue3.activate();
       added = office2.addBinding(new Binding(new SimpleCondition("myqueue2"), queue3, false), false);
       assertTrue(added);


       SimpleReceiver receiver0 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
       queue0.getLocalDistributor().add(receiver0);

       SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
       queue1.getLocalDistributor().add(receiver1);

       SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
       queue2.getLocalDistributor().add(receiver2);

       SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
       queue3.getLocalDistributor().add(receiver3);

       //Route to myqueue1 from office1        

       Message msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);     
       MessageReference ref = ms.reference(msg);        

       RouteResult routed = office1.route(ref, new SimpleCondition("myqueue1"), null);        
       assertTrue(routed.getResult());

       //Messages are sent asych so may take some finite time to arrive
       Thread.sleep(3000);

       //Only queue0 should get the message
       checkGetsMessage(queue0, receiver0, msg);

       checkNotGetsMessage(queue1, receiver1);

       checkNotGetsMessage(queue2, receiver2);

       checkNotGetsMessage(queue3, receiver3);

       //  Route to myqueue1 from office 2     

       msg = CoreMessageFactory.createCoreMessage(2, persistentMessage, null);     
       ref = ms.reference(msg);        

       routed = office2.route(ref, new SimpleCondition("myqueue1"), null);        
       assertTrue(routed.getResult());

       //Messages are sent asych so may take some finite time to arrive
       Thread.sleep(3000);

       //Only queue1 should get the message
       checkGetsMessage(queue1, receiver1, msg);

       checkNotGetsMessage(queue0, receiver0);

       checkNotGetsMessage(queue2, receiver2);

       checkNotGetsMessage(queue3, receiver3);


       //Now route to condition2 from office 1

       msg = CoreMessageFactory.createCoreMessage(3, persistentMessage, null);;     
       ref = ms.reference(msg);        

       routed = office1.route(ref, new SimpleCondition("myqueue2"), null);        
       assertTrue(routed.getResult());
       //Messages are sent asych so may take some finite time to arrive
       Thread.sleep(3000);

       // Only queue2 should get the message
       checkGetsMessage(queue2, receiver2, msg);

       checkNotGetsMessage(queue1, receiver1);

       checkNotGetsMessage(queue0, receiver0);

       checkNotGetsMessage(queue3, receiver3);


       //Now route to condition2 from office 2

       msg = CoreMessageFactory.createCoreMessage(4, persistentMessage, null);;     
       ref = ms.reference(msg);        

       routed = office2.route(ref, new SimpleCondition("myqueue2"), null);        
       assertTrue(routed.getResult());
       //Messages are sent asych so may take some finite time to arrive
       Thread.sleep(3000);

       // Only queue3 should get the message
View Full Code Here

       office2 = createClusteredPostOffice(2);


       Queue queue0 = new MessagingQueue(1, "sub1", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queue0.activate();
       boolean added = office1.addBinding(new Binding(new SimpleCondition("condition1"), queue0, false), false);
       assertTrue(added);

       Queue queue1 = new MessagingQueue(2, "sub2", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queue1.activate();
       added = office2.addBinding(new Binding(new SimpleCondition("condition1"), queue1, false), false);
       assertTrue(added);


       Queue queue2 = new MessagingQueue(1, "sub3", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queue2.activate();
       added = office1.addBinding(new Binding(new SimpleCondition("condition2"), queue2, false), false);
       assertTrue(added);

       Queue queue3 = new MessagingQueue(2, "sub4", channelIDManager.getID(), ms, pm, false, -1, null, true);
       queue3.activate();
       added = office2.addBinding(new Binding(new SimpleCondition("condition2"), queue3, false), false);
       assertTrue(added);


       SimpleReceiver receiver0 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
       queue0.getLocalDistributor().add(receiver0);

       SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
       queue1.getLocalDistributor().add(receiver1);

       SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
       queue2.getLocalDistributor().add(receiver2);

       SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
       queue3.getLocalDistributor().add(receiver3);

       //Route to condition1 from office1        

       Message msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);     
       MessageReference ref = ms.reference(msg);        

       RouteResult routed = office1.route(ref, new SimpleCondition("myqueue1"), null);        
       assertTrue(routed.getResult());

       //Messages are sent asych so may take some finite time to arrive
       Thread.sleep(3000);

       //Only queue0 should get the message
       checkGetsMessage(queue0, receiver0, msg);

       checkNotGetsMessage(queue1, receiver1);

       checkNotGetsMessage(queue2, receiver2);

       checkNotGetsMessage(queue3, receiver3);

       //  Route to myqueue1 from office 2     

       msg = CoreMessageFactory.createCoreMessage(2, persistentMessage, null);     
       ref = ms.reference(msg);        

       routed = office2.route(ref, new SimpleCondition("myqueue1"), null);        
       assertTrue(routed.getResult());

       //Messages are sent asych so may take some finite time to arrive
       Thread.sleep(3000);

       //Only queue1 should get the message
       checkGetsMessage(queue1, receiver1, msg);

       checkNotGetsMessage(queue0, receiver0);

       checkNotGetsMessage(queue2, receiver2);

       checkNotGetsMessage(queue3, receiver3);


       //Now route to condition2 from office 1

       msg = CoreMessageFactory.createCoreMessage(3, persistentMessage, null);;     
       ref = ms.reference(msg);        

       routed = office1.route(ref, new SimpleCondition("myqueue2"), null);        
       assertTrue(routed.getResult());
       //Messages are sent asych so may take some finite time to arrive
       Thread.sleep(3000);

       // Only queue2 should get the message
       checkGetsMessage(queue2, receiver2, msg);

       checkNotGetsMessage(queue1, receiver1);

       checkNotGetsMessage(queue0, receiver0);

       checkNotGetsMessage(queue3, receiver3);


       //Now route to condition2 from office 2

       msg = CoreMessageFactory.createCoreMessage(4, persistentMessage, null);;     
       ref = ms.reference(msg);        

       routed = office2.route(ref, new SimpleCondition("myqueue2"), null);        
       assertTrue(routed.getResult());
       //Messages are sent asych so may take some finite time to arrive
       Thread.sleep(3000);

       // Only queue3 should get the message
View Full Code Here

         // Add a couple of queues
        
         Queue queue1 = new MessagingQueue(1, "sub1", channelIDManager.getID(), ms, pm, false, -1, null, true);
         queue1.activate();

         Condition condition1 = new SimpleCondition("condition1");
        
         boolean added = office1.addBinding(new Binding(condition1, queue1, false), false);
         assertTrue(added);
              
         Queue queue2 = new MessagingQueue(1, "sub2", channelIDManager.getID(), ms, pm, false, -1, null, true);
         queue2.activate();

         added = office1.addBinding(new Binding(condition1, queue2, false), false);
         assertTrue(added);
              
         // Start another office - make sure it picks up the bindings from the first node
        
         office2 = createClusteredPostOffice(2);
          
         // Should return all queues
         Collection queues = office2.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(2, queues.size());
         assertTrue(queues.contains(queue1));
         assertTrue(queues.contains(queue2));
               
        
         // Add another queue on node 2
        
         Queue queue3 = new MessagingQueue(2, "sub3", channelIDManager.getID(), ms, pm, false, -1, null, true);
         queue3.activate();

         added = office2.addBinding(new Binding(condition1, queue3, false), false);
         assertTrue(added);
 
         // Make sure both nodes pick it up
        
         queues = office1.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(3, queues.size());
         assertTrue(queues.contains(queue1));
         assertTrue(queues.contains(queue2));
         assertTrue(queues.contains(queue3));
        
         queues = office2.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(3, queues.size());
         assertTrue(queues.contains(queue1));
         assertTrue(queues.contains(queue2));
         assertTrue(queues.contains(queue3));
       

         // Add another binding on node 2
        
         Queue queue4 = new MessagingQueue(2, "sub4", channelIDManager.getID(), ms, pm, false, -1, null, true);
         queue4.activate();

         added = office2.addBinding(new Binding(condition1, queue4, false), false);
         assertTrue(added);
        
         // Make sure both nodes pick it up
        
         queues = office1.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(4, queues.size());
         assertTrue(queues.contains(queue1));
         assertTrue(queues.contains(queue2));
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
        
         queues = office2.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(4, queues.size());
         assertTrue(queues.contains(queue1));
         assertTrue(queues.contains(queue2));
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
        
         // Unbind binding 1 and binding 2
         Binding removed = office1.removeBinding(queue1.getName(), false);
         assertNotNull(removed);
                 
         removed = office1.removeBinding(queue2.getName(), false);
         assertNotNull(removed);
        
         // Make sure bindings are not longer available on either node
        
         queues = office1.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(2, queues.size());
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
        
         queues = office2.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(2, queues.size());
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
        
        
         // Add a third office
                 
         office3 = createClusteredPostOffice(3);
        
         // Maks sure it picks up the bindings
        
         queues = office3.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(2, queues.size());
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
        
         // Add another binding on node 3
                 
         Queue queue5 = new MessagingQueue(3, "sub5", channelIDManager.getID(), ms, pm, false, -1, null, true);
         queue5.activate();
        
         added = office3.addBinding(new Binding(condition1, queue5, false), false);
         assertTrue(added);
        
         // Make sure all nodes pick it up
        
         queues = office1.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(3, queues.size());
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
         assertTrue(queues.contains(queue5));
        
         queues = office2.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(3, queues.size());
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
         assertTrue(queues.contains(queue5));
        
         queues = office3.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(3, queues.size());
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
         assertTrue(queues.contains(queue5));
        
         // Add a durable and a non durable binding on node 1
        
         Queue queue6 = new MessagingQueue(1, "sub6", channelIDManager.getID(), ms, pm, true, -1, null, true);
         queue6.activate();
        
         added = office1.addBinding(new Binding(condition1, queue6, false), false);
         assertTrue(added);
        
         Queue queue7 = new MessagingQueue(1, "sub7", channelIDManager.getID(), ms, pm, false, -1, null, true);
         queue7.activate();
        
         added = office1.addBinding(new Binding(condition1, queue7, false), false);
         assertTrue(added);
        
        
         // Make sure all nodes pick them up
        
         queues = office1.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(5, queues.size());
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
         assertTrue(queues.contains(queue5));
         assertTrue(queues.contains(queue6));
         assertTrue(queues.contains(queue7));
        
         queues = office2.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(5, queues.size());
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
         assertTrue(queues.contains(queue5));
         assertTrue(queues.contains(queue6));
         assertTrue(queues.contains(queue7));
        
         queues = office3.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(5, queues.size());
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
         assertTrue(queues.contains(queue5));
         assertTrue(queues.contains(queue6));
         assertTrue(queues.contains(queue7));
              
         // Stop office 1
         office1.stop();
 
         // Need to sleep since it may take some time for the view changed request to reach the
         // members which causes the bindings to be removed.
        
         Thread.sleep(3000);
        
         // All it's bindings should be removed from the other nodes, including durable
        
         queues = office2.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(3, queues.size());
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
         assertTrue(queues.contains(queue5));
        
         queues = office3.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(3, queues.size());
         assertTrue(queues.contains(queue3));
         assertTrue(queues.contains(queue4));
         assertTrue(queues.contains(queue5));
        
         // Stop office 2
         office2.stop();
        
         Thread.sleep(3000);
        
         queues = office3.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(1, queues.size());
         assertTrue(queues.contains(queue5));
        
         // Restart office 1 and office 2
         office1.start();
        
         office2.start();
                 
         queues = office1.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(2, queues.size());
         assertTrue(queues.contains(queue5));
         assertTrue(queues.contains(queue6));
        
         queues = office2.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(2, queues.size());
         assertTrue(queues.contains(queue5));
         assertTrue(queues.contains(queue6));
        
         queues = office3.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(2, queues.size());
         assertTrue(queues.contains(queue5));
         assertTrue(queues.contains(queue6));

         // Stop all offices
        
         office1.stop();
         office2.stop();
         office3.stop();
        
         // Start them all
         office1.start();
         office2.start();
         office3.start();
        
         // Only the durable queue should survive
        
         queues = office1.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(1, queues.size());
         assertTrue(queues.contains(queue6));
        
         queues = office2.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(1, queues.size());
         assertTrue(queues.contains(queue6));
        
         queues = office3.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertEquals(1, queues.size());
         assertTrue(queues.contains(queue6));      
        
         //Unbind it
        
         log.info("Removing queue6 binding");
         removed = office1.removeBinding(queue6.getName(), false);
         assertNotNull(removed);        
        
         queues = office1.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertTrue(queues.isEmpty());
        
         queues = office2.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertTrue(queues.isEmpty());
        
         queues = office3.getQueuesForCondition(condition1, false);
         assertNotNull(queues);
         assertTrue(queues.isEmpty());    
        
        
         //Bind another few more clustered
                          
         Queue queue8 = new MessagingQueue(1, "sub8", channelIDManager.getID(), ms, pm, false, -1, null, true);
         queue8.activate();
        
         Queue queue9 = new MessagingQueue(2, "sub9", channelIDManager.getID(), ms, pm, false, -1, null, true);
         queue9.activate();
        
         Queue queue10 = new MessagingQueue(2, "sub10", channelIDManager.getID(), ms, pm, false, -1, null, true);
         queue10.activate();
        
         //Bind on different conditions
        
         added = office1.addBinding(new Binding(condition1, queue8, false), false);
         assertTrue(added);
        
         added = office2.addBinding(new Binding(condition1, queue9, false), false);
         assertTrue(added);
        
         Condition condition2 = new SimpleCondition("condition2");
        
         added = office2.addBinding(new Binding(condition2, queue10, false), false);
         assertTrue(added);
        
         queues = office1.getQueuesForCondition(condition1, false);
View Full Code Here

                            
         //Durable
         Queue queue1 = new MessagingQueue(1, "sub1", channelIDManager.getID(), ms, pm, true, -1, null, true);
         queue1.activate();

         Condition condition1 = new SimpleCondition("condition1");
        
         //Add all binding
         boolean added = office1.addBinding(new Binding(condition1, queue1, true), true);
         assertTrue(added);
        
View Full Code Here

                          
         //Durable
         Queue queue1 = new MessagingQueue(1, "sub1", channelIDManager.getID(), ms, pm, true, -1, null, true);
         queue1.activate();

         Condition condition1 = new SimpleCondition("condition1");
        
         //Add all binding
         boolean added = office1.addBinding(new Binding(condition1, queue1, true), true);
         assertTrue(added);
        
View Full Code Here

                             
         //Durable
         Queue queue1 = new MessagingQueue(1, "sub1", channelIDManager.getID(), ms, pm, true, -1, null, true);
         queue1.activate();

         Condition condition1 = new SimpleCondition("condition1");
        
         //Add all binding
         boolean added = office1.addBinding(new Binding(condition1, queue1, true), true);
         assertTrue(added);
        
View Full Code Here

                          
         //Durable
         Queue queue1 = new MessagingQueue(1, "sub1", channelIDManager.getID(), ms, pm, true, -1, null, true);
         queue1.activate();

         Condition condition1 = new SimpleCondition("condition1");
        
         //Add all binding
         boolean added = office1.addBinding(new Binding(condition1, queue1, true), true);
         assertTrue(added);
        
View Full Code Here

                                  
         //Durable
         Queue queue1 = new MessagingQueue(1, "sub1", channelIDManager.getID(), ms, pm, true, -1, null, true);
         queue1.activate();

         Condition condition1 = new SimpleCondition("condition1");
        
         //Add all binding
         boolean added = office1.addBinding(new Binding(condition1, queue1, true), true);
         assertTrue(added);
        
View Full Code Here

                          
         //Durable
         Queue queue1 = new MessagingQueue(1, "sub1", channelIDManager.getID(), ms, pm, false, -1, null, true);
         queue1.activate();

         Condition condition1 = new SimpleCondition("condition1");
        
         //Add all binding
         boolean added = office1.addBinding(new Binding(condition1, queue1, true), true);
         assertTrue(added);
        
View Full Code Here

TOP

Related Classes of org.jboss.test.messaging.core.SimpleCondition

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.