1 Reply Latest reply on Mar 29, 2011 5:07 AM by Andy Taylor

    HornetQ - JMS-Bridge - HAJNDI Target

    Steven Landers Newbie

      Hello-

       

      If I set up a JMS-Bridge, can I make the target location an HA-JNDI-friendly location?

       

      For example, here's a tweaked version of the JNDI bean in the jms-bridge example:

       

      <bean name="HAJNDI" class="java.util.Hashtable">
               <constructor class="java.util.Map">
                  <map class="java.util.Hashtable" keyClass="String"
                                                   valueClass="String">
                     <entry>
                        <key>java.naming.factory.initial</key>
                        <value>org.jnp.interfaces.NamingContextFactory</value>
                     </entry>
                     <entry>
                        <key>java.naming.provider.url</key>
                        <value>jnp://queue:1200,queuebackup:1200</value>
                     </entry>
                     <entry>
                        <key>java.naming.factory.url.pkgs</key>
                        <value>org.jboss.naming:org.jnp.interfaces"</value>
                     </entry>
                  </map>
               </constructor>
            </bean>
      

       

      I'd essentially like to know if this would reconnect to queuebackup:1200 upon an inability to connect to queue:1200.

       

      Thanks -

      Steven