WSO2 ESB Dynamic End Point Resolution

From WSO2 ESB 4.7.0 onwards, support dynamic end point resolutions.

If you have multiple deployment environments (DEV, QA, Production), then you may end up having many endpoints and will have to change them once you migrate your synapse configs to other environment. As a simple solution for this time consuming problem (for Call out mediator and send mediator only), you can initialize end points as jvm parameters at the server start up.


  1. SEND Mediator

                <endpoint name="MyEp"

    You have to create a endpoint template in order to use this feature for send mediator. When you start the ESB, you can initialize the {} and {system.prop.bpm.stock.port} by using JVM parameters as follows. And then those end points will be initialized correctly.    - Dbpm.stock.port=..................

  2. CALLOUT Mediator
Callout mediator will be same as send mediator. you can initialize the parameters with jvm parameters

   <callout serviceURL="http://{}:{system.prop.bpm.stock.port}/services/SimpleStockQuoteService"
            <source xmlns:s12=""
                    xpath="s11:Body/child::*[fn:position()=1] | s12:Body/child::*[fn:position()=1]"/>
            <target xmlns:s12=""
                    xpath="s11:Body/child::*[fn:position()=1] | s12:Body/child::*[fn:position()=1]"/>


Popular posts from this blog

WSO2 ESB Removing full soap header using enrich mediator.

WSO2 ESB append full body to a POST parameter

WSO2 ESB Script Mediator (Remove body of an soap envelop)