Friday, April 11, 2008

Why timeout property is not working ?

When we call a synchronous webservice we can specify how much we want to wait for the response to come back before the sytem level timeout occurs.

This is acheived with "timeout" property added to the partnerlink binding in the bpel.xml.

ex:
<partnerlinkbinding name="CallCreditService">
<property name="wsdlLocation">http://KBITRA-LAP:7777/orabpel/default/TestHello/TestHello?wsdl</property>
<property name="timeout">30</property>

so you are waiting for this to timeout in 30seconds but does not appear to be working and the system level timeout occurs.

The reason for this is this property works when the invocation happens on soap stack, when bpel calling another bpel process as you know by now automatically switches this soap call to be local binding call. In order to achieve this you have to add another property called "optSoapShortcut to false" in the bpel.xml for that partner link

How to do it: Steps

1. Open BPEL project from Jdeveloper
2. Open bpel.xml look for "partnerLinkBinding" for the partner you are trying to invoke and add the following property tag inside.
false

So here is the changed version:

<partnerLinkBinding name="CallCreditService">
<property name="wsdlLocation">http://KBITRA-LAP:7777/orabpel/default/TestHello/TestHello?wsdl</property>
<property name="timeout">30</property>
<property name="optSoapShortcut">false</property>
</partnerLinkBinding>

1 comment:

shreedevi said...

This post was very useful. Thanks a lot for this..