nickva opened a new pull request, #5635: URL: https://github.com/apache/couchdb/pull/5635
Add property tests for couch_btree. It's a central data structure for CouchDB so it's important we test it well. After creating the test noticed it immediately found an error. Apparently we allowed creating duplicate B-tree entries. The duplicate entries could not be reached with the regular lookups and queries, but could still be streamed out using using folds. That's clearly broken behavior for couch_btree. Luckily, it seems we had mananged to protect the main by_id B-tree and view index one from this, since before inserting we group entries by ID. To fix the issue, remove duplicate inserts and removes in query_modify during the pre-processing stage. We cannot do the same thing for queries, as the user will expect to get the exact number of results to match their lookup keys (to possibly zip the two together to match them up later). -- 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]
