Hi all,

I have a situation where, although extremely rare and really should only 
arise while debugging, one of my Async calls returns and executes its 
callback before the calling function/main loop is done with its execution. 
This has only been done in Dev mode and not prod.

Now I know (or at least I'm pretty pretty sure) that in JS the async 
callback is pushed onto the event stack to evaluate next when it returns, 
thus it is called only after the calling JS execution returns and would not 
interrupt currently running JS to execute. Even the gwt doc states 
"Although the code inside the onSuccess() method is defined inline with the 
call, it will not be executed until both the calling code returns back to 
the JavaScript main loop, and the result message from the server returns." 
at the end 
of 
https://developers.google.com/web-toolkit/doc/latest/DevGuideServerCommunication#DevGuideGettingUsedToAsyncCalls
 
.

So my question is "am I seeing this behavior only because it is in Dev mode 
and is actually just because Java is running with threads or is this 
actually possible in Prod too? "

Thanks a lot in advance,

-Seth

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to