incubator-couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Roger Binns <>
Subject Re: _rewrite handler
Date Sun, 06 Dec 2009 06:50:04 GMT
Hash: SHA1

Benoit Chesneau wrote:
> Well rewrite need to be fast. I don't like the idea of loading another
> doc. However since ddoc is already loaded  it could be used in. We
> just spoke with jchris about such possibily. I think that it will do
> the trick.

That is certainly better in my opinion than no doc at all.

> You don't need to regerenate code you can use couchapp macro or any
> templating system in current solution. 

You are thinking as though you maintain couchapp :-)  Sure that is no
problem for the developer of a CouchApp but consider what happens once you
deploy it.  For example lets say there is a blogging CouchApp that people(*)
use and it has a debugging mode implemented by a rewrite  (eg it rewrites
shows/lists with -debug suffix).  It is far easier to change a single key on
the design doc (or whatever doc is presented to the _rewrite function) than
to require that user to download and install couchapp, edit the correct
files and redeploy.

(*) As CouchDB becomes more successful the administrators and users of
CouchApps will increasingly have no knowledge of Javascript, what REST is,
how all the pieces fit together etc.  Consider trying to explain how to
change a rewrite function versus telling them to go to futon and change a
key in the appropriate doc.

Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla -


View raw message