Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support one purge request with more than 100 docid #1865

merged 1 commit into from Jan 18, 2019


Copy link

@jiangphcn jiangphcn commented Jan 17, 2019


This PR is aimed to solve the following error when sending one purge request with more than 100 docid.


Testing recommendations

make check skip_deps+=couch_epi apps=chttpd tests=purge_test_
chttpd db tests
Application crypto was left running!
  chttpd_purge_tests:88: test_empty_purge_request...[0.019 s] ok
  chttpd_purge_tests:105: test_ok_purge_request...[0.232 s] ok
  chttpd_purge_tests:142: test_ok_purge_request_with_101_docid...[3.268 s] ok
  chttpd_purge_tests:162: test_accepted_purge_request...[0.243 s] ok
  chttpd_purge_tests:194: test_partial_purge_request...[0.087 s] ok
  chttpd_purge_tests:230: test_mixed_purge_request...[0.188 s] ok
  chttpd_purge_tests:278: test_overmany_ids_or_revs_purge_request...[0.124 s] ok
  chttpd_purge_tests:328: test_exceed_limits_on_purge_infos...[0.148 s] ok
  chttpd_purge_tests:371: should_error_set_purged_docs_limit_to0...[0.003 s] ok
  chttpd_purge_tests:379: test_timeout_set_purged_infos_limit...[0.188 s] ok
[os_mon] cpu supervisor port (cpu_sup): Erlang has closed
  [done in 7.484 s]

Related Issues or Pull Requests



  • Code is written and works correctly;
  • Changes are covered by tests;
  • Documentation reflects the changes;
@jiangphcn jiangphcn requested a review from davisp Jan 17, 2019
davisp approved these changes Jan 17, 2019
Copy link

@davisp davisp left a comment



Copy link

@davisp davisp commented Jan 17, 2019

For history, this was because the initial accumulator being {ok, []} ended up causing us to create an improper list which blew up on [1] when we exceeded 100 elements to reorder.


KeyDict = dict:from_list(SortedResults),


Copy link
Contributor Author

@jiangphcn jiangphcn commented Jan 18, 2019

thanks @davisp for additional explanation.


@jiangphcn jiangphcn merged commit a3f99df into master Jan 18, 2019
1 check passed
@jiangphcn jiangphcn deleted the purge_request_with_101_docid branch Jan 18, 2019
Copy link

@wohali wohali commented Jan 18, 2019

@jiangphcn Please be careful with your JIRA issue tagging - you linked this one to "Build under snap container is denied access to /bindf" - not the right issue.

We're not using JIRA any more, so you probably don't need to reference any COUCHDB-#### issues from this point forward. Feel free to reference GitHub issues if they exist, though.

(I only notice this because I closed out every single JIRA issue, so I get personal email every time one of them gets updated.)


Copy link
Contributor Author

@jiangphcn jiangphcn commented Jan 19, 2019

thanks Joan @wohali for reminder. Will follow later.


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants