BPEL timeout after 120 seconds - Apache ODE - Tomcat

368 Views Asked by At

I'm new to bpel. I've made a webservice with a pick activity and it works fine. But when i change the onAlarm duration to more than 120 seconds, i get an timeout error! Is it possible to change the timeout duration for apache ode? Any XML file where i can change the max timeout?

BPEL process flow: ReceiveInput -> invoke asynchronous process -> pick activity with two paths (onMessage and onAlarm) -> onMessage waits for callback from the asynchronous process (this process has a wait activity for 5min) -> after one of these opportunities is triggered, i just assign a string ("onMessage" or "onAlarm") to the output variable and reply it to the client.

2

There are 2 best solutions below

0
Fezi32 On BEST ANSWER

I solved the problem by add an .endpoint file to /ode/WEB-INF/conf. Just add this lines to the file:

# 10 minutes
mex.timeout=600000

For more information look: http://ode.apache.org/endpoint-configuration.html

1
vanto On

This sounds like you are invoking the process with a two-way/synchronous operation. This is an antipattern because if you have a long running process between receive/pick and reply, those timeouts are to be expected. Increasing the timeout will only delay the problem. The general advice in such scenarios is to switch to an asynchronous communication model with two one-way messages, i.e. use <invoke> on a callback operation for the response instead of a <reply>. BPEL's partnerlinks help to tie both interfaces together.