Comet

By Deane Barker on April 10, 2006

Comet: Low Latency Data for the Browser: I think the end of the request-response model of HTTP communications is upon us. This reverses Ajax — using Comet (still not quite sure how it’s done), the server can reach out and contact the browser at will.

Comet applications can deliver data to the client at any time, not only in response to user input. The data is delivered over a single, previously-opened connection. This approach reduces the latency for data delivery significantly.

Gadgetopia
What Links Here

Comments

  1. Comet applications can deliver data to the client at any time, not only in response to user input. The data is delivered over a single, previously-opened connection.

    While this is probably a good thing for a programmer, could it not also be a bad thing in the hands of a spammer or hacker or someone with not so honorable intentions?

  2. What they’re really talking about here is HTTP streaming. On the small scale, throw a loop with a sleep() in it in a PHP page, flush the output on every loop, and there you go.

    Unfortunately, this won’t scale well with your average web server. The client holds open the connection, which means a tied-up thread or process on Apache. It doesn’t take many concurrent users holding open the thread to tie up the whole server.

    There are some things starting to emerge that alleviate this issue, but use with caution on your average web server.

  3. Am I the only one who remembers push? Where the HTTP server would push page segments in mime parts, over an open connection. Guess it was a few years too early, and only Mozilla added support for it. Would have been quite useful now though, sepecially if combined with a neat client side api, such as the now famous XmlHttp.

  4. Am I the only one who remembers push? Where the HTTP server would push page segments in mime parts, over an open connection.

    The old-school “Push”, as I remember it, was The It Thing That Would Change The Net ’round the days of IE4’s launch. Pointcast was a revolutionary concept, deserving of all your investment dollars.

    Of course, the dirty little secret of old-school push was that it was just pull with a schedule, Pointcast was a screensaver, and there wasn’t much money in showing ads to people that went to lunch ten minutes ago.

    (Incredibly, Pointcast seems to still be around).

  5. It was hyped alright, but no credible ‘products’ where ever developed that utilized it… probably why it was pulled.

    Pull on schedule: That’s true for the IE implementation, but the old Netscape one actually used a persistent connection and sent mime encoded pages, forcing the server to keep a lot of connections open, but at least it was true push.

Comments are closed. If you have something you really want to say, email editors@gadgetopia.com and we‘ll get it added for you.