We use pushlets with some success for our dynamic HTML updates in a web application. Specifically, anytime new alerts are added to a database table, the JSP frame we use to display them realtime is updated. I know very little of AJAX apart from the buzzword. Can this tech help me reduce the overhead involved with pushlets?
Probably not, since the main thrust of AJAX is "Pull" rather than "Push". The user performs some action, such as dragging an item to her shopping cart. The AJAX JavaScript code then sends the data for the selected item in a POST to the webservlet and the user can go on shopping or whatever. When the webserver returns the result (extended price, subtotal, sales tax, shipping, etc.) the listener that has been set in the AJAX app's JavaScript is invoked, the XML in the result is parsed for the data and then the existing DOM is modified by the JavaScript to replace and/or add the data from the XML to the existing form on the webpage.
Note that the possibly extensive HTML for the form itself is not resent to the browser, nor is the browser screen repainted, the data in the form widgets (or any other HTML elements on the page) are changed with a user experience that is much more like a desktop application.
I don't see any reason why the Pushlet and AJAX can't work together.
I just released Pushlets v2.0.2 which has support for AJAX through a JavaScript library. So I don't think it is either Pushlets or AJAX. So check it out: www.pushlets.com An example is www.geotracing.com where Pushlets (w. AJAX) are used for real-time GPS tracking on a Google Map.
Just
Post by:autobot
New rule: no elephants at the chess tournament. Tiny ads are still okay.
a bit of art, as a gift, the permaculture playing cards