activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From christophe blin <cb...@tennaxia.com>
Subject how to configure an embed broker with an optional tcp transport
Date Thu, 19 Oct 2006 08:39:27 GMT

Hi,

I'd like to configure an embed broker that use vm and tcp transport, but
with the tcp tranport being optional.
At the moment, if I use a blank value for the tcp transport, then the bean
initialisation failed (see at the bottom of this message).

If this is not very clear, here is an example of what I'd like to do.

The following is working :

  <bean id="broker" class="org.apache.activemq.xbean.XBeanBrokerService">
    <property name="persistenceAdapter">
      <bean class="org.apache.activemq.store.jdbc.JDBCPersistenceAdapter">
        <property name="dataSource" ref="ds" />
      </bean>
    </property>
    <property name="transportConnectorURIs">
      <list>
        <value>vm://localhost</value>
        <value>tcp://localhost:61365</value><!-- and sometimes
<value></value> -->
      </list>
    </property>
    <property name="start" value="true" />
  </bean>

What I'd like is to externalize the "tcp://localhost:61365" into a
properties file and to make it optional (i.e if the user said
"jms.embedbroker=" then I do not want the exception to appear)

exception that appear if I use a blank value :
org.springframework.beans.factory.BeanCreationException: Error creating bean
with name 'broker' defined in class path resource [jms-spring.xml]:
Invocation of init method failed; nested exception is java.io.IOException:
Transport not scheme specified: []

thanks for any help,
regards,
chris
-- 
View this message in context: http://www.nabble.com/how-to-configure-an-embed-broker-with-an-optional-tcp-transport-tf2471995.html#a6892699
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Mime
View raw message