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 types from explain API #46926

Merged
merged 5 commits into from
Sep 23, 2019

Conversation

romseygeek
Copy link
Contributor

We no longer need a type to get the source of a document, so we can remove it from
the explain API as well.

Relates to #41059

@romseygeek romseygeek added :Search/Search Search-related issues that do not fall into other categories >breaking-java >refactoring v8.0.0 labels Sep 20, 2019
@romseygeek romseygeek self-assigned this Sep 20, 2019
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-search

@jpountz jpountz mentioned this pull request Sep 20, 2019
66 tasks
Copy link
Contributor

@jtibshirani jtibshirani left a comment

Choose a reason for hiding this comment

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

This looks good to me, I just had a small comment.

public ExplainRequest(String index, String id) {
this.index = index;
this.id = id;
}

ExplainRequest(StreamInput in) throws IOException {
super(in);
type = in.readString();
if (in.getVersion().before(Version.V_8_0_0)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

To be safe, we could read the type but assert that it is _doc (similarly to what we did in #42198).

@romseygeek
Copy link
Contributor Author

@elasticmachine update branch

@romseygeek romseygeek merged commit b733f9e into elastic:master Sep 23, 2019
@romseygeek romseygeek deleted the types-removal/explain-action branch September 23, 2019 16:55
@pgomulka pgomulka mentioned this pull request Mar 25, 2020
66 tasks
pgomulka added a commit that referenced this pull request Jun 9, 2021
retrofits the typed endpoints for rest explain api removed in #46926

relates #51816
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>breaking-java >refactoring :Search/Search Search-related issues that do not fall into other categories v8.0.0-alpha1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants