couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brian Candler <>
Subject Re: Restricting user interactions to a single document -- was [VOTE] Apache CouchDB 0.9.0 release
Date Thu, 02 Apr 2009 15:44:45 GMT
On Wed, Apr 01, 2009 at 09:05:37AM +1030, Antony Blakey wrote:
> On 31/03/2009, at 11:14 PM, Brian Candler wrote:
>> Perhaps you want some sort of lock manager, whereby a client can  
>> request a
>> lock on a group of documents, perform an update, then release the  
>> lock?
> Then you need deadlock detection due to ordering of lock acquisition.  
> Better to use the higher level concept of an atomic _bulk_docs.

Yeah, but CouchDB [TM] doesn't have that, so I'm suggesting an alternative.

There are plenty of simple algorithms to avoid lock ordering problems. If I
remember correctly, I think that just sorting the doc_ids you're interested
in and grabbing them in ascending order should be sufficient.

View raw message