Showing posts from July, 2010

Message format transformations with WSO2 ESB

With WSO2 ESB , you can easily convert the format of the messages which passes through. There are situations in which you get SOAP requests but the back end server accepts XML. In these situations, you should convert the SOAP request to XML (POX) before forwarding to the endpoint. This post explains how you can change the format of a SOAP request goes through WSO2 ESB. Pre-requisites: Download and install WSO2 ESB-3.X Step 1 I use WSO2 WSAS as the backend, but you could use any server as you preferred. Start WSO2 WSAS and deploy Axis2Service Step 2 Start WSO2 ESB and add the following configuration. Here, we specify the message format as POX in the endpoint configuration since we need to convert SOAP message to XML when forwarding it to the endpoint. <sequence xmlns="" name="main"> <in> <send> <endpoint name="axis2service-epr"> <address uri="http://localhost:9763/s

How to use POST_TO_URI property in WSO2 ESB

Until recently I had some doubts about using POST_TO_URI property within WSO2 ESB configuration. Finally, I think I understood the true purpose of it and used it correctly. According to WSO2 ESB parameters catelog , POST_TO_URI property makes the outgoing URL of the ESB a complete URL and it is important when sending the messages through a proxy server. Lets see how this property can be used in message mediation when a HTTP proxy server is used. Step 1 As I explained in a previous post , you are supposed to configure WSO2 ESB to forward messages through a HTTP proxy server. Step 2 Now, add the following sequence (or any message pass through sequence). (I used a service called "Axis2Sesrvice" which is deployed on WSO2 WSAS as the endpoint and I used Apache server as the proxy) <sequence xmlns="" name="main"> <in> <send> <endpoint name="endpoint_urn_uuid_1286CEB97BC8A17046844515099591

How to configure WSO2 ESB to route messages through a proxy server

When using WSO2 ESB , there are situations in which you need to talk to an endpoint which sits behind a proxy. In such cases, you should configure the ESB transport sender to forward the messages to the proxy server. In order to do so, you just need to add the following two parameters as child elements of <transportSender name="http" class="org.apache.synapse.transport.nhttp.HttpCoreNIOSender"> <parameter name="http.proxyHost" locked="false">localhost</parameter> <parameter name="http.proxyPort" locked="false">8090</parameter> Note:- Change the proxy port and host according to your environment