[Mongrel] Comet style requests with mongrel

Todd Fisher todd.fisher at gmail.com
Sat Nov 24 12:33:16 EST 2007


You might find this interesting.

 http://adam.blogs.bitscribe.net/2007/05/08/comet-with-rails-mongrel/
 http://code.google.com/p/rlogwatch/

-Todd

On Nov 23, 2007 5:23 PM, Zed A. Shaw <zedshaw at zedshaw.com> wrote:
> On Fri, 23 Nov 2007 16:26:04 +0000
> Jeremy Wilkins <jeremy at ibexinternet.co.uk> wrote:
>
> > Hi,
> >
> > I've been doing some experiments with php and if can use something like
> >
> > <?php
> >
> > for ($i = 0; $i < 100; $i++) {
> >       echo "hello world";
> >       flush();
> >       sleep(10);
> > }
> >
> > ?>
> >
> > to keep a http link open for an arbitrary amount of time and
> > routinely display "hello world" in the browser window.
> >
> > Is is possible to write a mongrel handler to do something similar?
>
> Yep, you could probably write a handler to do that, but probably not a rails action without tons of surgery.
>
> However, this will fall down pretty quick once you hit Ruby's 1024 (or less) file descriptor limit due to its use of select.
>
> Zed
>
> _______________________________________________
> Mongrel-users mailing list
> Mongrel-users at rubyforge.org
> http://rubyforge.org/mailman/listinfo/mongrel-users
>


More information about the Mongrel-users mailing list