0
votes

We are using WSO2 ESB 4.0.3 with Data services feature on MAC OSX 10.7.4.

I have proxy service which forwards the message to Data Service. When there is any fault in Data service the fault is returned to calling proxy service in OUTSEQUENCE. Now if there is any error I forward this to common error handler from proxy service which happens in OUTSEQUENCE. This common error handler is another proxy service only.

Now when the Error handling is completed the control returns back to original proxy service which called the error handling proxy service. But what happens is when the control returns to original proxy service from error handler it AGAIN starts executing the OUTSEQUENCE of proxy service.

So for me it is executing the OUTSEQUENCE of proxy service twice in case of fault from Data Service.

Is it standard behavior? I used to Java kind of executing where when the call from method returns it starts executing the next line. But here looks like it again starts executing the OUTSEQUENCE from beginning.

To avert executing the OUTSEQUENCE from beginning again I populate the value at "transport" scope in Error hanlder proxy which will used in filter mediator to avoid executing the logic in OUTSEQUENCE twice.

I am trying to find if there are any SOAP headers I can use instead of setting the property. I see no SOAP headers being set like "From" or "ReplyTo" and I believe message co-ordination happens with MessageId. How can we use these SOAP headers instead of property to divert the flow logic.

Please help. thanks Abhijit

1

1 Answers

0
votes

In this case instead of using send mediator to invoke the web service you can use the call out mediator. Which makes a blocking call to error handling service and returns to the same place.

And also with esb 4.0.3 you can specify the receive sequence at the send mediator level. By default the response is received at the outsequence level. eg. <send receive="fundTransferSequence"> <endpoint> <address encoding="UTF-8" statistics="disable" uri="http://10.1.23.11:8888/EgateValidWS/EgateValidWSSoapHttpPort" >

    &lt;/address&gt;
&lt;/endpoint&gt;

</send>