Navigation Menu

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

Remove queries for _all_docs, _design_docs and _local_docs #1143

Merged

Conversation

jiangphcn
Copy link
Contributor

Overview

In the #1032, queries are supported to _all_docs, _design_docs and _local_docs to address the requirement in #820.
However, the response schema changes depending on what is POSTed. This makes it quite hard to interact with from static type languages. So we plan to move the implementation to separate endpoint. As the first step, this PR is used to remove queries for _all_docs, _design_docs and _local_docs.

Testing recommendations

make check skip_deps+=couch_epi apps=chttpd tests=all_test_

==> chttpd (eunit)
Compiled test/chttpd_db_test.erl
Compiled src/chttpd_db.erl
    Running test function(s):
      chttpd_db_doc_size_tests:all_test_/0
      chttpd_db_test:all_test_/0
      chttpd_security_tests:all_test_/0
======================== EUnit ========================
chttpd security tests
Application crypto was left running!
  chttpd_security_tests:120: should_allow_admin_db_compaction...[0.003 s] ok
  chttpd_security_tests:137: should_allow_valid_password_to_create_user...ok
  chttpd_security_tests:147: should_disallow_invalid_password_to_create_user...ok
  chttpd_security_tests:155: should_disallow_anonymous_db_compaction...ok
  chttpd_security_tests:163: should_disallow_db_member_db_compaction...ok
  chttpd_security_tests:166: should_allow_db_admin_db_compaction...[0.002 s] ok
  chttpd_security_tests:176: should_allow_admin_view_compaction...[0.009 s] ok
  chttpd_security_tests:191: should_disallow_anonymous_view_compaction...ok
  chttpd_security_tests:194: should_allow_admin_db_view_cleanup...[0.002 s] ok
  chttpd_security_tests:209: should_disallow_anonymous_db_view_cleanup...ok
[os_mon] cpu supervisor port (cpu_sup): Erlang has closed
  [done in 5.346 s]
chttpd db tests
  chttpd_db_test:81: should_return_ok_true_on_bulk_update...[0.048 s] ok
  chttpd_db_test:108: should_accept_live_as_an_alias_for_continuous...[0.034 s] ok
  chttpd_db_test:123: should_return_404_for_delete_att_on_notadoc...[0.005 s] ok
  chttpd_db_test:145: should_return_409_for_del_att_without_rev...[0.040 s] ok
  chttpd_db_test:163: should_return_200_for_del_att_with_rev...[0.061 s] ok
  chttpd_db_test:184: should_return_409_for_put_att_nonexistent_rev...[0.010 s] ok
  chttpd_db_test:199: should_return_update_seq_when_set_on_all_docs...[0.134 s] ok
  chttpd_db_test:213: should_not_return_update_seq_when_unset_on_all_docs...[0.077 s] ok
  chttpd_db_test:227: should_return_correct_id_on_doc_copy...[0.086 s] ok
[os_mon] cpu supervisor port (cpu_sup): Erlang has closed
  [done in 2.029 s]
chttpd db max_document_size tests
  chttpd_db_doc_size_tests:84: post_single_doc...ok
  chttpd_db_doc_size_tests:92: put_single_doc...ok
  chttpd_db_doc_size_tests:101: bulk_doc...ok
  chttpd_db_doc_size_tests:127: put_post_doc_attach_inline...ok
  chttpd_db_doc_size_tests:128: put_post_doc_attach_inline...ok
  chttpd_db_doc_size_tests:129: put_post_doc_attach_inline...ok
  chttpd_db_doc_size_tests:130: put_post_doc_attach_inline...ok
  chttpd_db_doc_size_tests:152: put_multi_part_related...ok
  chttpd_db_doc_size_tests:153: put_multi_part_related...ok
  chttpd_db_doc_size_tests:177: post_multi_part_form...ok
  chttpd_db_doc_size_tests:178: post_multi_part_form...ok
[os_mon] cpu supervisor port (cpu_sup): Erlang has closed
  [done in 1.162 s]
=======================================================
  All 30 tests passed.

Related Issues or Pull Requests

#820
#1032

Checklist

  • Code is written and works correctly;
  • Changes are covered by tests;
  • Documentation reflects the changes;

@jiangphcn jiangphcn force-pushed the issue-820-remove-queries-for_all_docs branch from 670f350 to 1446e87 Compare February 6, 2018 13:47
@wohali
Copy link
Member

wohali commented Feb 6, 2018

Can you describe what the new endpoints are?

Other than the new endpoint moving, are you making backwards-incompatible changes to endpoints other than the new one introduced?

If so we need to be careful about this landing in 2.x.

Copy link
Contributor

@iilyak iilyak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@iilyak iilyak merged commit 3b53c1c into apache:master Feb 6, 2018
@iilyak iilyak deleted the issue-820-remove-queries-for_all_docs branch February 6, 2018 21:54
@wohali
Copy link
Member

wohali commented Feb 6, 2018

As @rnewson just said on IRC, and as I asked above, this should not have landed without discussion.

You can't just remove pre-existing features (not the new one that was merged post 2.1.1) without a discussion. We have customers depending on this.

Please revert ASAP!

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

Successfully merging this pull request may close these issues.

None yet

3 participants