priyen commented on code in PR #10926: URL: https://github.com/apache/pinot/pull/10926#discussion_r1252422716
########## pinot-segment-local/src/main/java/org/apache/pinot/segment/local/aggregator/DistinctCountHLLValueAggregator.java: ########## @@ -100,6 +124,9 @@ public byte[] serializeAggregatedValue(HyperLogLog value) { @Override public HyperLogLog deserializeAggregatedValue(byte[] bytes) { + if (bytes == null || bytes.length == 0) { + return new HyperLogLog(_log2m); + } Review Comment: deserializeAggregatedValue is often called in getInitialAggregatedValue of some of the implementations (not just HLL or sum precision), one example is in AvgValueAggregator when the input is of type bytes, so to cover that case, I also do it here -- 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: commits-unsubscr...@pinot.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org For additional commands, e-mail: commits-h...@pinot.apache.org