We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Describe the bug A NullPointerException occurs when the methods minBound() and maxBound
NullPointerException
minBound()
maxBound
OpenSearch/server/src/main/java/org/opensearch/search/aggregations/bucket/histogram/HistogramAggregationBuilder.java
Lines 228 to 236 in 8844f05
DoubleBounds
OpenSearch/server/src/main/java/org/opensearch/search/aggregations/bucket/histogram/DoubleBounds.java
Lines 154 to 160 in 8844f05
To Reproduce A unit test that does not set the min and max values, example for the minBound:
public void testNPE() { HistogramAggregationBuilder factory = new HistogramAggregationBuilder("foo"); try { factory.minBound(); } catch (Exception e) { assertThat(e, instanceOf(NullPointerException.class)); } }
Expected behavior It should return null
null
Host/Environment (please complete the following information):
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Describe the bug
A
NullPointerException
occurs when the methodsminBound()
andmaxBound
OpenSearch/server/src/main/java/org/opensearch/search/aggregations/bucket/histogram/HistogramAggregationBuilder.java
Lines 228 to 236 in 8844f05
are called before they are set in
DoubleBounds
OpenSearch/server/src/main/java/org/opensearch/search/aggregations/bucket/histogram/DoubleBounds.java
Lines 154 to 160 in 8844f05
To Reproduce
A unit test that does not set the min and max values, example for the minBound:
Expected behavior
It should return
null
Host/Environment (please complete the following information):
The text was updated successfully, but these errors were encountered: