couchdb - How to access server variables from an update function? -


in particular i'm trying access doc_count (of requested db), i'd know how access rest of server, as possible.

you can database document's count req.info.doc_count variable. see request object structure more info. inspect own requests may use dummy update function:

function(doc, req){   return [null, {"json": req}] } 

however, server data can access update functions.