jonenst
jonenst

Reputation: 349

wso2 externalize jms broker ip from axis2.xml

I currently define the jms broker ip in axis2.xml :

<transportReceiver name="jms" class="org.apache.axis2.transport.jms.JMSListener">
    <parameter name="default" locked="false">
        <parameter name="java.naming.provider.url" locked="false">failover:tcp://IP_OF_BROKER:61616</parameter>
        ...
    </parameter>
</transportReceiver>

and use it in proxy services:

<proxy name="MyJmsQueue" transports="jms">
...
</proxy>

How do I put the ip and port of the jms broker outside of the axis2.xml file ?

Note: the reason why I want it outside is that the axis2.xml contains a lot of 'technical' configurations that do not depend on the environement (testing, production etc). But the ip and port of the jms broker typically changes (just like the ip and port of any backend services).

Upvotes: 0

Views: 43

Answers (1)

Chandana
Chandana

Reputation: 2638

If you want to externalize JMS configuration from the axis2 XML file, you can use JMS Inbound Protocol. This is a cleaner way to implement and you can pack all of your configurations through a CAR file. You can find more details and an example about JMS Inbound Protocol by going through the official documentation.

Upvotes: 1

Related Questions