[Eventmachine-talk] Erlang-like Processes

Francis Cianfrocca
Tue, 28 Aug 2007 17:36:59 -0000

On 8/28/07, Mark Van De Vyver <mvyver at gmail.com>
wrote:
>
>
> ... that this heads-up was appreciated.  I''ve implemented handling
a
> ''custom'' TCP protocol using EM and the next step was to
consider
> EM#defer :)
>
> Thanks
> Mark



Inquiring minds want to know, Mark. What was your experience like,
implementing the custom protocol? Any problems or rough spots?

EM#defer works with a pool of Ruby threads managed by EM. It''s
indispensable
for certain things (like making blocking calls to database libraries) but
should be avoided for everything else. EM works perfectly well in the
presence of Ruby threads, but Ruby''s thread scheduler exacts an
INCREDIBLE
performance penalty (with or without EM), and you really should avoid
threads in performance-sensitive code.
-------------- next part --------------
An HTML attachment was scrubbed...