You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@couchdb.apache.org by GitBox <gi...@apache.org> on 2020/08/14 01:02:19 UTC

[GitHub] [couchdb] eiri opened a new pull request #3078: Validate shard specific query params on db create request

eiri opened a new pull request #3078:
URL: https://github.com/apache/couchdb/pull/3078


   ## Overview
   
   Db creation request accepts shard specific parameters q, n and placement, but passes them to fabric without validation. This leads to badarg crash in case of invalid parameter.
   
   The patch adds validation on all the parameters and raises error 400 in case of failure.
   
   ## Testing recommendations
   
   A command `$ curl -u $(ADMIN):$(PASS) -X PUT -v "http://localhost:5984/test?q="` should return error `400`
   
   New tests added in chttpd_db.erl module:
   
   `make eunit apps=chttpd suites=chttpd_db`
   
   ## Related Issues or Pull Requests
   
   Back-port of #3077 
   
   ## Checklist
   
   - [x] Code is written and works correctly
   - [x] Changes are covered by tests
   - [ ] Any new configurable parameters are documented in `rel/overlay/etc/default.ini`
   - [ ] A PR for documentation changes has been made in https://github.com/apache/couchdb-documentation
   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [couchdb] eiri merged pull request #3078: Validate shard specific query params on db create request

Posted by GitBox <gi...@apache.org>.
eiri merged pull request #3078:
URL: https://github.com/apache/couchdb/pull/3078


   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org