couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Owen Marshall <>
Subject Re: One view per "query"?
Date Fri, 10 Jun 2011 13:15:07 GMT
At Fri, 10 Jun 2011 12:05:20 +0200,
Daniele Testa wrote:

> Another question I have is what benefit do I get when putting several
> views in one design document?

Views within the same design document are indexed together, saving space and speeding up view

> As I understood, this just causes problems like that all views needs
> to update, thus locking all the views in the design document.

I was also concerned about this at first, but in my experience, CouchDB updates views *very*
quickly. My application's write rate is significantly less than CouchDB's update rate.

If your application doesn't behave like that, you can always:

* query with stale=ok as appropriate
* hit the views more often, reducing latency

Owen Marshall
FacilityONE | (502) 805-2126

View raw message