apache / nano

Nano is now part of Apache CouchDB. Repo moved to https://GitHub.com/apache/couchdb-nano

Home Page:https://github.com/apache/couchdb-nano

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Allow forcing GET on VIEW commands (even with keys)

libHive opened this issue · comments

This issue rose when working against Cloudant. Their pricing is 5 times cheaper for GET requests than POST requests. I had a lot of requests for small sets of keys, nothing that couldn't go into a query string, and I had made this change in order to keep my bills down.

The actual change was rather small - just adding an optional parameter to the request -

  let exampleQuery = { 
            reduce : true, 
            group : true, 
            keys : [ [a,b], [c,d] ], 
            forceGet: true // this is the parameter I added
        }; 

Do you think this is something that should go into the main branch ?
Thanks

This repository has been merged into apache/couchdb-nano, please continue the discussion here