nickva opened a new pull request, #5515:
URL: https://github.com/apache/couchdb/pull/5515

   Previously, we set a default limit that was an effective "infinity" (2^28). 
However, that turned out to be too low and it surprised a user when it 
truncated their all_docs output skipping the rest of the data. Fix that by 
increasing the limit to 100B.
   
   We have a "query_limit" config parameter to increase the limit, however that 
turned out to be broken and did not take effect, when the user tried, so fix 
that as well.
   
   Since we still support using the local API (localhost:5986 or _node/$node), 
and the worker function is used for the clustered and local calls, the 
`apply_limit/2` function is called twice for the same request: once on the 
coordinator, and then on each worker. Since the coordinator sets `limit` as 
`limit+skip`, that means that we'd be failing all `skip > 0` calls on the 
coordinator (`limit + skip > max_limit`). To handle that, use an extra option 
flag to indicate that we already applied the limit and don't apply it again.
   
   When running the tests also discovered that our `_dbs_info` and `list` 
endpoints did not validate query parameters, so ensure we validate them, which 
means users can now configure query limits for them.
   
   Fix #5176
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to