couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tim Parkin <>
Subject Re: Bulk Docs - 'remove changes so far' Functionality?
Date Mon, 16 Mar 2009 10:14:16 GMT
Damien Katz wrote:
> There is an all_or_nothing option for bulk updates, it does
> validation/security checks on the documents, and if all pass then it
> saves all the documents. If there is a failure or db crash during the
> commit, none of the documents are saved. However, it does not check for
> conflicts, documents are saved regardless if the conflict.
> You can do all or nothing bulk updates with conflict checking by
> serializing updates at the app level (or use a programmable reverse
> proxy) and check bulk updates before committing to see if they'll
> conflict. With the all_or_nothing flag, you'll get exactly the behavior
> you desire.

Hi Damian,

A couple of questions..

1) For the average developer who is making changes across a bunch of
documents and wants all of the changes to work or none of them, can you
recommend a workflow to help deal with conflicts?

With bulk_docs this is a trivial operation on a single node (which is
where most sharded changes will be applied) but with partial
successes/partial conflicts, I'm not sure how to make sure things get
cleaned up/reverted correctly?

2) If we wanted to include bulk_docs in a fork, do the new changes mean
the old bulk_docs is impossible or has it just been switched off and not


View raw message