Examples of goOn()


Examples of org.apache.activemq.util.SocketProxy.goOn()

        Session session = c.createSession(true, Session.SESSION_TRANSACTED);
        MessageConsumer consumer = session.createConsumer(dest);
        proxy.pause();
        // writes should back up... writeTimeout will kick in a abort the connection
        TimeUnit.SECONDS.sleep(10);
        proxy.goOn();
        assertNotNull("can receive buffered messages", consumer.receive(500));
        try {
            session.commit();
            fail("expect commit to fail as server has aborted writeTimeout connection");
        } catch (JMSException expected) {
View Full Code Here

Examples of org.apache.activemq.util.SocketProxy.goOn()

        //dumpAllThreads("blocked on write");
       
        // abort should be done after this
        TimeUnit.SECONDS.sleep(4);

        proxy.goOn();
       
        // get a buffered message
        frame = stompConnection.receiveFrame();
        assertTrue(frame.startsWith("MESSAGE"));
       
View Full Code Here

Examples of org.apache.activemq.util.SocketProxy.goOn()

        Session session = c.createSession(true, Session.SESSION_TRANSACTED);
        MessageConsumer consumer = session.createConsumer(dest);
        proxy.pause();
        // writes should back up... writeTimeout will kick in a abort the connection
        TimeUnit.SECONDS.sleep(10);
        proxy.goOn();
        assertNotNull("can receive buffered messages", consumer.receive(500));
        try {
            session.commit();
            fail("expect commit to fail as server has aborted writeTimeout connection");
        } catch (JMSException expected) {
View Full Code Here

Examples of org.apache.activemq.util.SocketProxy.goOn()

        //dumpAllThreads("blocked on write");
       
        // abort should be done after this
        TimeUnit.SECONDS.sleep(4);

        proxy.goOn();
       
        // get a buffered message
        frame = stompConnection.receiveFrame();
        assertTrue(frame.startsWith("MESSAGE"));
       
View Full Code Here

Examples of org.apache.activemq.util.SocketProxy.goOn()

        Session session = c.createSession(true, Session.SESSION_TRANSACTED);
        MessageConsumer consumer = session.createConsumer(dest);
        proxy.pause();
        // writes should back up... writeTimeout will kick in a abort the connection
        TimeUnit.SECONDS.sleep(10);
        proxy.goOn();
        assertNotNull("can receive buffered messages", consumer.receive(500));
        try {
            session.commit();
            fail("expect commit to fail as server has aborted writeTimeout connection");
        } catch (JMSException expected) {
View Full Code Here

Examples of org.apache.activemq.util.SocketProxy.goOn()

        //dumpAllThreads("blocked on write");

        // abort should be done after this
        TimeUnit.SECONDS.sleep(10);

        proxy.goOn();

        // get a buffered message
        frame = stompConnection.receiveFrame();
        assertTrue(frame.startsWith("MESSAGE"));
View Full Code Here

Examples of org.apache.activemq.util.SocketProxy.goOn()

            }
        });

        // wait for timeout and reconnect
        TimeUnit.SECONDS.sleep(8);
        proxy.goOn();
        for (int i=0; i<messageCount; i++) {
            assertNotNull("Got message " + i  + " after reconnect", consumer.receive(5000));
        }

        assertTrue("no pending messages when done", Wait.waitFor(new Wait.Condition() {
View Full Code Here

Examples of org.apache.activemq.util.SocketProxy.goOn()

                LOG.info("DestView {} comsumerCount {}", destView, destView.getConsumerCount());
                return 0 == destView.getConsumerCount();
            }
        }));

        socketProxy.goOn();

        assertTrue("consumer was closed", Wait.waitFor(new Wait.Condition() {
            @Override
            public boolean isSatisified() throws Exception {
                boolean closed = false;
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.