itamarst / eliot

Eliot: the logging system that tells you *why* it happened
https://eliot.readthedocs.io
Apache License 2.0
1.1k stars 66 forks source link

Make MemoryLogger thread-safe #383

Closed exarkun closed 5 years ago

exarkun commented 5 years ago

Fixes #382

exarkun commented 5 years ago

I protected all of the MemoryLogger methods with a lock but I only wrote a test for MemoryLogger.write. This is kind of lazy, I guess.

itamarst commented 5 years ago

Only testing write seems reasonable, it's the only part of the public interface that is likely to be called from multiple threads.

itamarst commented 5 years ago

Thanks for the patch!