[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: LMDB: fast writes: removing the write mutex ?

MDB_NOLOCK doesn't fit, from the doc Â:

Don't do any locking. If concurrent access is anticipated, the caller must manage all concurrency itself.

I still want the concurrency managed on reads.Â

On Fri, Apr 25, 2014 at 3:06 PM, Hallvard Breien Furuseth <hbf@mail.uio.no> wrote:
I wrote:
On 13. april 2014 18:04, Simon Majou wrote:

In that case, how can I disable the write lock ?
Would commenting LOCK_MUTEX_W() & UNLOCK_MUTEX_W() make the trick ?

You could use MDB_NOTLS in LMDB 0.9.7 or later, but then you must
synchronize threads yourself which does not sound like what you
want. Also, then you must not write when there are too old readers.

Oops, I meant MDB_NOLOCK. ÂMDB_NOTLS is about readers.


Best regards,