wmoustafa commented on code in PR #6004:
URL: https://github.com/apache/iceberg/pull/6004#discussion_r1156306507


##########
core/src/main/java/org/apache/iceberg/avro/ValueReaders.java:
##########
@@ -612,6 +615,9 @@ protected StructReader(
         } else if (field.fieldId() == MetadataColumns.IS_DELETED.fieldId()) {
           positionList.add(pos);
           constantList.add(false);
+        } else if (record.getField(field.name()) == null && 
field.initialDefault() != null) {

Review Comment:
   In the latest patch, `record` is no longer required in this method. The 
default value is set here similar using a mechanism similar to `positions` and 
`constants` and then it is used in the `read()` method. Removing dependency on 
`record` simplified this API and a few others as `Schema record` is no longer 
required in the signature (similar to before this patch).



-- 
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]

Reply via email to