in order to achieve better web server scalability under server push scenarios, you'll need to use something called "comet" technology. Jetty implements it in the form of its Continuations extension (http:// docs.codehaus.org/display/JETTY/Continuations). Apache Tomcat also does have it (http://tomcat.apache.org/tomcat-6.0-doc/aio.html). These implementations are container specific, but allow the java servlet container to scale to hundreds, if not thousands, of concurrent comet connections. You can read more about comet-style implementations with GWT on Jetty and Tomcat in GWT Apps book's instant messenger example (http://www.gwtapps.com/?page_id=31). The source code for the comet implementation from this book can also be found here - http://groups.google.com/group/gwtapps/files
I hope this helps. Tim http://gwtnow.com On Aug 24, 9:04 pm, breder <[EMAIL PROTECTED]> wrote: > Can someone answer me, please > > On Aug 19, 7:19 am, breder <[EMAIL PROTECTED]> wrote: > > > More one question about the 'freeze' a response > > :http://code.google.com/p/google-web-toolkit-incubator/wiki/ServerPushFAQ > > " > > Server Threads > > > In order to 'freeze' a response, you would usually freeze the thread. > > In a servlet, you might for example do something like: > > > synchronized ( chatMessages ) { > > while ( chatMessages.size() < 200 ) try { > > chatMessages.wait(); > > } catch ( InterruptedException e ) { > > respond("Server interrupted. Chat Session Closed."); > > } > > respond(chatMessages.get(200)); > > > where, if anyone types something, you wake any frozen threads by > > using: > > > synchronized ( chatMessages ) { > > chatMessages.add(theNewChatLine); > > chatMessages.notifyAll(); > > } > > " > > > with if way, if i have 1000 client connect with me, i will have 1000 > > thread waiting in my server. It is a good idea to have the same number > > of thread and client? > > > On Aug 18, 4:31 pm, Charlie Collins <[EMAIL PROTECTED]> wrote: > > > > You might want to look at the getting started guide info > > > -http://code.google.com/webtoolkit/documentation/com.google.gwt.doc.De.... > > > > (But I don't really follow the question, if you mean server push, then > > > you can find more info here > > > -http://code.google.com/p/google-web-toolkit-incubator/wiki/ServerPushFAQ). > > > > On Aug 17, 11:58 am, breder <[EMAIL PROTECTED]> wrote: > > > > > I want to know if there are any chance for Server can talk with > > > > Cliente to do something. It is good for client to be updated for yours > > > > thinks in server. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~----------~----~----~----~------~----~------~--~---
