[Haskell-cafe] Bringing Erlang to Haskell
Bulat Ziganshin
bulatz at HotPOP.com
Tue Dec 13 05:05:42 EST 2005
Hello Tomasz,
Tuesday, December 13, 2005, 12:49:04 PM, you wrote:
TZ> On Mon, Dec 12, 2005 at 04:00:46PM +0000, Joel Reymont wrote:
>> One particular thing that bugs me is that I cannot really use TChan
>> for thread mailboxes. I don't think I experienced this problem with
>> Erlang but using a TChan with a logger thread quickly overwhelms the
>> logger and fills the TChan and a lot (hundreds? thousands) of other
>> threads are logging to it.
TZ> I wonder what Erlang does to solve this problem? Perhaps we should track
TZ> the number of unprocessed messages in TChans and the bigger it is
TZ> the more favor consumers over producers.
even best - always prefer consumer to producer :) may be have two
lists - one of threads waiting to consume, and one of threads waiting to
produce?
--
Best regards,
Bulat mailto:bulatz at HotPOP.com
More information about the Haskell-Cafe
mailing list