Asynchronous work - what are our options?

75 views
Skip to first unread message

markww

unread,
Sep 10, 2012, 11:31:33 PM9/10/12
to google-we...@googlegroups.com
Hi,

I was hoping to do some asynchronous work, though I do not believe this is possible (due to the limitations of javascript). The work I need to do is not an http request, it's computing some AI stuff for a game. If I understand correctly:
  1. RPC is reserved only for http communication. There's no way to just launch an asynchronous task where my own clientside code is run in the async handler.
  2. There are now things called "web workers" as part of html5, but GWT doesn't have wrappers for them yet?
Thanks

Brandon Donnelson

unread,
Sep 10, 2012, 11:43:44 PM9/10/12
to google-we...@googlegroups.com
I'd use web workers. If you can't find a wrapper library, you can call the native javascript through jsni methods. 

Speed tracers has a nice example:

Andrea Boscolo

unread,
Sep 11, 2012, 8:40:32 AM9/11/12
to google-we...@googlegroups.com
Elemental should support it.
And there are also other wrappers here and there that work too.
Reply all
Reply to author
Forward
0 new messages