ode-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Frembs <michael.fre...@gmx.de>
Subject eventHandler
Date Mon, 21 May 2012 12:47:49 GMT
Hi,

I have a question about the eventHandler. In the spec it says:

"These event handlers can run concurrently and are invoked when the 
corresponding event occurs."

So I would expect that it fires immediately or at least directly after 
the actual activity ends. I build a testcase which behaves very strange. 
The testcase starts with an asynchronous call to an echo service. 
Following up by a while loop (in the body of the loop is one assign 
activity) and about 70 assign activities. Each activity does the same: 
increments a counter. Concurrently an eventHandler is implemented 
waiting for the response of the echo service. By activating it stores 
the actual counter value to the output.

I would expect following behaviour:
Each run a different number returns. It depends on how fast the answer 
of the echo service arrives. But what I get is the following (I 
manipulate the while loop) :
100 loops: <initialValue> / the eventHandler doesn't fire
500 loops: <initialValue> / the process takes round about 4 seconds
1000 loops: <initialValue> / ~ 7 seconds

Within this 7 seconds the answer should arrive (the echo web service is 
on localhost).

When I go back to 100 loops and add a wait (1 second) activity directly 
after "while" I receive 100.0 as result. The process lasts ~3 seconds.

I testet further and to conclude this: The eventHandler only fires if a 
wait activity is implemented - otherwise the reply never receives. So 
can you explain me how the eventHandler works in detail and when it fires?

Here you can find the sample:
http://www.file-upload.net/download-4379036/NextTry.zip.html

Thanks, Michael

P.S. I use ODE 1.3.5

Mime
View raw message