qiref commented on code in PR #27348:
URL: https://github.com/apache/flink/pull/27348#discussion_r2633557786
##########
flink-runtime/src/main/java/org/apache/flink/runtime/metrics/DescriptiveStatisticsHistogramStatistics.java:
##########
@@ -172,7 +172,7 @@ private void maybeInitPercentile() {
if (percentilesImpl == null) {
percentilesImpl = new
Percentile().withNaNStrategy(NaNStrategy.FIXED);
}
- if (data != null) {
+ if (data != null && data.length > 0) {
Review Comment:
Done! Added tests that specifically target the NullArgumentException
scenario. The bug is now immortalized in our test suite. Tests can be verified
with:
```
mvn test -pl flink-runtime -Dtest=DescriptiveStatisticsHistogramTest
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]