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

[DOCS] Add search pagination docs #56785

Merged
merged 5 commits into from
May 15, 2020
Merged

[DOCS] Add search pagination docs #56785

merged 5 commits into from
May 15, 2020

Conversation

jrodewig
Copy link
Contributor

@jrodewig jrodewig commented May 14, 2020

Reworks the from / size content to Paginate search results.

Moves those docs from the Request body search API docs page
(slated for deletion) to the Run a search tutorial docs.

Also adds some notes to the from and size param docs.

Because this involves redirects, I only plan to merge into master. I'll be backporting to all maintained branches.

Relates to #48194

Reworks the `from / size` content to `Paginate search results`.

Moves those docs from the request body search API page (slated for
deletion) to the `Run a search` tutorial docs.

Also adds some notes to the `from` and `size` param docs.
@jrodewig jrodewig added >docs General docs changes :Search/Search Search-related issues that do not fall into other categories v8.0.0 labels May 14, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-search (:Search/Search)

@elasticmachine elasticmachine added the Team:Search Meta label for search team label May 14, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-docs (>docs)

@elasticmachine elasticmachine added the Team:Docs Meta label for docs team label May 14, 2020
@jrodewig jrodewig mentioned this pull request May 14, 2020
28 tasks
Copy link
Contributor

@debadair debadair left a comment

Choose a reason for hiding this comment

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

Left some comments--the wording of the offset piece, in particular, definitely needs to be changed.

docs/reference/search/request/from-size.asciidoc Outdated Show resolved Hide resolved
docs/reference/search/request/from-size.asciidoc Outdated Show resolved Hide resolved
Comment on lines 13 to 19
[IMPORTANT]
====
The combined document count, including offset and and returned documents, for
the `from` and `size` parameters cannot exceed the
<<index-max-result-window,`index.max_result_window`>> index setting, which
defaults to 10,000 documents.
====
Copy link
Contributor

Choose a reason for hiding this comment

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

I think the point here is that by default, you can page through a maximum of 10,000 documents. I'd say that, and then xref the settings, but probably not as a note. Instead,
I'd pull some of the cautionary info about deep paging into an important note from the definitive guide.

@@ -87,6 +87,14 @@ both parameters are specified, only the query parameter is used.
include::{docdir}/rest-api/common-parms.asciidoc[tag=from]
+
--
[IMPORTANT]
Copy link
Contributor

Choose a reason for hiding this comment

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

Some combo of only being able to page through 10k docs by default and the warning about deep paging would need to go replace these admonitions, as well.

jrodewig and others added 3 commits May 15, 2020 08:07
Co-authored-by: debadair <debadair@elastic.co>
Co-authored-by: debadair <debadair@elastic.co>
@jrodewig
Copy link
Contributor Author

Thanks for your review @debadair, particularly your help with the from sentence.

I've made some other adjustments based on your feedback with a1d3c9f.

I think this is ready for another review at your convenience.

@jrodewig jrodewig requested a review from debadair May 15, 2020 12:27
Copy link
Contributor

@debadair debadair left a comment

Choose a reason for hiding this comment

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

Looks good!

@jrodewig
Copy link
Contributor Author

Thanks!

@jrodewig jrodewig merged commit 56d7af0 into elastic:master May 15, 2020
@jrodewig jrodewig deleted the docs__paginate-search-results branch May 15, 2020 21:22
jrodewig added a commit that referenced this pull request Jun 1, 2020
Reworks the `from / size` content to `Paginate search results`.

Moves those docs from the request body search API page (slated for
deletion) to the `Run a search` tutorial docs.

Also adds some notes to the `from` and `size` param docs.

Co-authored-by: debadair <debadair@elastic.co>
jrodewig added a commit that referenced this pull request Jun 1, 2020
Reworks the `from / size` content to `Paginate search results`.

Moves those docs from the request body search API page (slated for
deletion) to the `Run a search` tutorial docs.

Also adds some notes to the `from` and `size` param docs.

Co-authored-by: debadair <debadair@elastic.co>
jrodewig added a commit that referenced this pull request Jun 1, 2020
Reworks the `from / size` content to `Paginate search results`.

Moves those docs from the request body search API page (slated for
deletion) to the `Run a search` tutorial docs.

Also adds some notes to the `from` and `size` param docs.

Co-authored-by: debadair <debadair@elastic.co>
@jrodewig
Copy link
Contributor Author

jrodewig commented Jun 1, 2020

Backport commits

master 56d7af0
7.x 994781f
7.8 e7516fc
7.7 f31e172

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>docs General docs changes :Search/Search Search-related issues that do not fall into other categories Team:Docs Meta label for docs team Team:Search Meta label for search team v7.7.2 v7.8.1 v7.9.0 v8.0.0-alpha1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants