arina-ielchiieva commented on a change in pull request #1387: DRILL-6603: Set 
num_nulls for parquet statistics to -1 when actual number is not defined.
URL: https://github.com/apache/drill/pull/1387#discussion_r203682260
 
 

 ##########
 File path: 
exec/java-exec/src/main/java/org/apache/drill/exec/store/parquet/metadata/MetadataBase.java
 ##########
 @@ -108,6 +105,18 @@
 
 
   public static abstract class ColumnMetadata {
+
+    /**
+     * Number of nulls is considered to be valid if its value is not null and 
-1.
+     *
+     * @return true if nulls value is defined, false otherwise
+     */
+    @JsonIgnore
+    public boolean isNullsDefined() {
+      Long nulls = getNulls();
 
 Review comment:
   Previously created Drill metadata files might have nulls defined as null. 
Agree that renaming is good idea but since it will affect several versions of 
`ColumnMetadata` class which is used in ser /de when creating Drill parquet 
metadata files, I'd rather not make such changes right now. Since PR resolves 
release blocker, I suggest we keep changes at minimum to avoid possible 
regressions. Created Jira for the improvement - 
https://issues.apache.org/jira/browse/DRILL-6620.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to