commitlog icon indicating copy to clipboard operation
commitlog copied to clipboard

Multi reader writer

Open goldenMetteyya opened this issue 8 years ago • 2 comments

Have you thought about multiple writer support?

goldenMetteyya avatar Feb 27 '17 23:02 goldenMetteyya

Multiple readers (as in multiple threads) could be fairly straightforward to support.

Multiple writers (as in threads) would be tricky. You could get away with having multiple segment (one per thread)s and reading from each on read... but that also gets messy. Batching is usually the best way to handle concurrent appends. I've implemented this in my other project w/ futures support (https://github.com/zowens/chain-replication/blob/master/log-server/asynclog/mod.rs)

zowens avatar Feb 28 '17 18:02 zowens

Okii I think that the batching approach is a good one. I will try and add multi reader support into this crate

goldenMetteyya avatar Mar 06 '17 22:03 goldenMetteyya