[Haskell-cafe] Concurrency best practices?
Jesper Louis Andersen
jesper.louis.andersen at gmail.com
Sat Feb 5 17:19:48 CET 2011
On Sat, Feb 5, 2011 at 17:13, Andrew Coppin <andrewcoppin at btinternet.com> wrote:
> On 05/02/2011 12:56 PM, Jesper Louis Andersen wrote:
>
> Presumably messages added to the channel appear immediately after the
> transaction commits. The problem is, I think GHC's STM implementation might
> mean that if two transactions both try to log a message, they both get
> rolled back...
>
Yes, this is the performance caveat I was hinting at. When logging
becomes heavy and transactions are *not* completing, you will have
transaction retries due to the logging. If the transaction completes
however, it is not that much of a problem.
--
J.
More information about the Haskell-Cafe
mailing list