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

Fix an NPE when requesting inner hits and _source is disabled. #44836

Merged
merged 2 commits into from
Jul 25, 2019

Conversation

jtibshirani
Copy link
Contributor

@jtibshirani jtibshirani commented Jul 24, 2019

This PR makes two changes to FetchSourceSubPhase when _source is disabled and
we're in a nested context:

  • If no source filters are provided, return early to avoid an NPE.
  • If there are source filters, make sure to throw an exception.

The behavior was chosen to match what currently happens in a non-nested context.

Addresses #43517.

This PR makes two changes to FetchSourceSubPhase when _source is disabled and
we're in a nested context:
* If no source filters are provided, return early to avoid an NPE.
* If there are source filters, make sure to throw an exception.

The behavior was chosen to match what currently happens in a non-nested context.
@jtibshirani jtibshirani added >bug :Search/Search Search-related issues that do not fall into other categories v8.0.0 v7.4.0 labels Jul 24, 2019
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-search

@jtibshirani jtibshirani removed the WIP label Jul 25, 2019
@jtibshirani
Copy link
Contributor Author

@elasticmachine run elasticsearch-ci/packaging-sample

Copy link
Contributor

@jimczi jimczi left a comment

Choose a reason for hiding this comment

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

LGTM

@jtibshirani jtibshirani merged commit 729aca5 into elastic:master Jul 25, 2019
@jtibshirani jtibshirani deleted the nested-with-source-disabled branch July 25, 2019 17:34
jtibshirani added a commit that referenced this pull request Jul 25, 2019
This PR makes two changes to FetchSourceSubPhase when _source is disabled and
we're in a nested context:
* If no source filters are provided, return early to avoid an NPE.
* If there are source filters, make sure to throw an exception.

The behavior was chosen to match what currently happens in a non-nested context.
jkakavas pushed a commit that referenced this pull request Jul 31, 2019
This PR makes two changes to FetchSourceSubPhase when _source is disabled and
we're in a nested context:
* If no source filters are provided, return early to avoid an NPE.
* If there are source filters, make sure to throw an exception.

The behavior was chosen to match what currently happens in a non-nested context.
jtibshirani added a commit that referenced this pull request Aug 12, 2019
This PR makes two changes to FetchSourceSubPhase when _source is disabled and
we're in a nested context:
* If no source filters are provided, return early to avoid an NPE.
* If there are source filters, make sure to throw an exception.

The behavior was chosen to match what currently happens in a non-nested context.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>bug :Search/Search Search-related issues that do not fall into other categories v7.3.1 v7.4.0 v8.0.0-alpha1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants