On Tue, Apr 20, 2010 at 9:47 PM, Brian Candler <[email protected]> wrote:

> This is because the ruby 1.8 interpreter is basically one big 'select' loop.
> C extensions are supposed to call rb_thread_select to pass control back to
> the interpreter until a particular fd is ready for reading or writing - but
> 0mq provides a blocking C API.

Afaik there are about 20 Ruby interpreters, are there not?  Some
multithreaded, some not?

Perhaps a general solution is to move the 0MQ work to a separate
process and talk to that.  It can run at full speed and queue stuff up
for the Ruby app to take when it needs it.

This could work as a full-speed model for other languages too.  Why
involve the interpreter in message processing at all?

-Pieter
_______________________________________________
zeromq-dev mailing list
[email protected]
http://lists.zeromq.org/mailman/listinfo/zeromq-dev

Reply via email to