Assume the following synapse configuration.
<proxy name="StockQuoteProxy">
<target faultSequence="myFaultHandler">
<inSequence>
<!-- in sequence goes here -->
</inSequence>
<outSequence>
<!-- out sequence goes here -->
</outSequence>
</target>
<publishWSDL
uri="file:repository/conf/sample/resources/proxy/sample_proxy_1.wsdl"/>
</proxy>
<sequence name="myFaultHandler">
<!-- fault sequence -->
</sequence>
It seems that the synapse ignores executing the fault handler
'myFaultHandler' when an exception is thrown in outSequence of the proxy
definition.
By looking at the code I can see that the registered fault handler only take
effect in inSequence, reason is the registered fault handler only added only
into out message context. But when we define a fault handler for the proxy
it should handle both exceptions occurs in in sequence and out sequence.
I fixed the problem by sharing the defined fault handler in, in message
context as well ( I have attached the diff). If you agree with the solution
I can provide this as patch.
Rajika
--
http://rajikak.blogspot.com/
proxy-out-sequence-fault.patch
Description: Binary data
--------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
