it happens randomly that RPC calls "hang", eg callback methods are not
invoked.
I have not been able to figure out why or under which circumstances
this happens. It does not occur very often.
Is this an error on the client side ? or server ? There are no
exceptions thrown on the server side.
I therefore tend to implement a timeout for RPC calls, to assure that
the application does not get stuck.
However I find that this feature should be part of GWT.
A possible solution could be to add the method
ServiceDefTarget.setTimeout(long) and call
AsyncCallback.onFailure(TimeoutException)
A similar request for HTTPRequest has been mentioned earlier.
http://groups.google.com/group/Google-Web-Toolkit/browse_frm/thread/9b1b04d93893d9ac/7095afe70cf58b29?lnk=st&q=&rnum=40#7095afe70cf58b29
Comments ? Suggestions ?
I've just started working with GWT, but also thought about what happen
if server would be too busy to answer quick. I haven't yet wrote any
workaround, but thought about using Timer: start timer just before
starting async request and stop it on success. And if timer is not
stopped, show some info to user (e.g. "Sorry, server is too busy now,
try later" :)).
This solution is very straight, but should work. Can you describe way
that You tend to implement timeouts for RPC?
WBR, Valentyn Shybanov
http://olostan.org.ua/
yes, similar to what you propose.
- Ron