Package org.apache.activemq.broker

Examples of org.apache.activemq.broker.BrokerService.stop()


                       
            LOG.info("Success");

        } finally {
            if (broker != null) {
                broker.stop();
            }
        }
    }

    /*
 
View Full Code Here


            assertTrue("Should have created a journal directory at " + journalFile.getAbsolutePath(), journalFile.exists());

            LOG.info("Success");
        } finally {
            if (broker != null) {
                broker.stop();
            }
        }
    }

    /*
 
View Full Code Here

            assertTrue("Should have not created a journal directory at " + journalFile.getAbsolutePath(), !journalFile.exists());

            LOG.info("Success");
        } finally {
            if (broker != null) {
                broker.stop();
            }
        }

    }
View Full Code Here

        broker = createBroker(new FileSystemResource(CONF_ROOT + "memory-example.xml"));
        try {
            assertEquals("Broker Config Error (brokerName)", "brokerMemoryConfigTest", broker.getBrokerName());
        } finally {
            if (broker != null) {
                broker.stop();
            }
        }

        broker = createBroker("org/apache/activemq/config/config.xml");
        try {
View Full Code Here

        broker = createBroker("org/apache/activemq/config/config.xml");
        try {
            assertEquals("Broker Config Error (brokerName)", "brokerXmlConfigHelper", broker.getBrokerName());
        } finally {
            if (broker != null) {
                broker.stop();
            }
        }
    }

    /*
 
View Full Code Here

                consumer.close();
                session.close();
                connection.close();

                broker.stop();
            }
        });
    }

    public void runTest(Task task) throws Exception {
View Full Code Here

            } catch (final Throwable t) {
                t.printStackTrace();
            }
            try {
                if (brokerService2 != null) {
                    brokerService2.stop();
                }
            } catch (final Throwable t) {
                t.printStackTrace();
            }
        }
View Full Code Here

                in.close();
            }
        }

        connection.close();
        broker.stop();
    }
}
View Full Code Here

        for (int i =0; i < 1000; i++) {
            Message msg = session.createTextMessage("test message:"+i);
            producer.send(msg);
        }
        connection.stop();
        broker.stop();
    }
   
    public void testVersionConversion() throws Exception{
        File testDir = new File("target/activemq-data/kahadb/versionDB");
        IOHelper.deleteFile(testDir);
View Full Code Here

        for (int i = 0; i < 1000; i++) {
            TextMessage msg  = (TextMessage) topicConsumer.receive(10000);
            //System.err.println(msg.getText());
            assertNotNull(msg);
        }
        broker.stop();
       
    }

   
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.