On Thu, Oct 2, 2008 at 3:37 AM, Dejan Bosanac
<[EMAIL PROTECTED]> wrote:
> If you are taking this route, you can try defining your broker
> configuration in a separate xml file and do something like
>
> BrokerService broker = BrokerFactory.createBroker(new
> URI("xbean:activemq.xml"));
> broker.start();
>
> it will be easier to configure it that way.

Use of the BrokerFactoryBean is also very easy with the activemq.xml:

BrokerFactoryBean brokerFactory = new BrokerFactoryBean(new
ClassPathResource("path/to/activemq.xml"));
brokerFactory.afterPropertiesSet();
BrokerService broker = brokerFactory.getBroker();

Bruce
-- 
perl -e 'print unpack("u30","D0G)[EMAIL 
PROTECTED]&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*"
);'

Apache ActiveMQ - http://activemq.org/
Apache Camel - http://activemq.org/camel/
Apache ServiceMix - http://servicemix.org/

Blog: http://bruceblog.org/

Reply via email to