You will need to download the following:
1. Tomcat 6 (binary release, for Windows I downloaded the zip version)
2. the gwt-comet-examples-1.1.4.war file
3. I’m going to assume you have the Java JDK installed.
Extract Tomcat to a folder on your machine (assuming you downloaded the zip version). Modify the
“tomcat-users.xml” file in the “conf” folder so we have an admin account:
<tomcat-users> <role rolename="admin"/> <role rolename="manager"/> <user username="admin" password="password" roles="admin,manager"/> <user username="manager" password="password" roles="manager"/> </tomcat-users>
Go into the “bin” directory of Tomcat now and run the startup script (Startup.bat on Windows). Fire up a browser and head to this address: http://localhost:8080/ Click on the “Tomcat Manager” link and enter the admin username and password you used in the “tomcat-users.xml” file.
Go to the “WAR File to deploy” section and press the “Choose File” button and locate the downloaded “gwt-comet-examples-1.1.4.war” file. Press the “Deploy” button and wait a bit for it to fully unpack and deploy.
You should see it show up now in the “Applications” section:
Assuming everything went well and the WAR was successfully deployed you can now test it out at this address: http://localhost:8080/gwt-comet-examples-1.1.4/net.zschech.gwt.chat.Chat/Chat.html
Set your username and begin chatting. Open another browser (I used Chrome and IE) and voila, you have a GWT chat web app using Comet. If you are interested you can browse the source code to this chat app here.
You might be interested to know that there is already support for websockets in this project.
You can access the gwt-comet user group here.