keuin commented on code in PR #3586:
URL: https://github.com/apache/parquet-java/pull/3586#discussion_r3298406999
##########
parquet-column/src/main/java/org/apache/parquet/column/impl/ColumnValueCollector.java:
##########
@@ -54,6 +58,7 @@ class ColumnValueCollector {
}
void resetPageStatistics() {
+ this.nullCount = 0;
this.statistics = statisticsEnabled
? Statistics.createStats(path.getPrimitiveType())
: Statistics.noopStats(path.getPrimitiveType());
Review Comment:
It's possible, but putting it outside `Statistics` is a design choice. By
reading code I think the `Statistics` object is a 1:1 mapping to parquet
header's `statistics` object, which is optional and may be disabled by user.
Putting counter of `num_nulls` outside `statistics` object makes the code
clearer, because the code maps clearly to parquet header structure.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]