couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Hendricks <>
Subject Re: Optionally including docs in view results
Date Wed, 06 Aug 2008 14:09:20 GMT
On Wed, Aug 06, 2008 at 12:23:51PM +0100, Tom Wright wrote:
> Having had a bit of time to stew on this issue, I'm coming to the 
> conclusion that there needs to be more of a separation of concerns.
> Fetching records should not be lumped into the same call as updating / 
> inserting / deleting - ie. _bulk_docs. However, I reckon _bulk_docs as it 
> is is trying to do too much - why not go for something like the following:
> _bulk_get
> _bulk_insert
> _bulk_update
> _bulk_delete
> This way, a request will only ever have one purpose, and the response can 
> be simpler and more relevant, especially where errors are concerned. Maybe 
> change insert / update for put / post in terms of naming, but you get the 
> idea.

Allowing insert, update and delete operations in a single request is
quite useful though.  It allows for a transaction so that I can insert a
new document and update another document to point to it and be assured
that the database's integrity is maintained.  If one part fails, the
whole thing fails.


View raw message