codope commented on code in PR #11467:
URL: https://github.com/apache/hudi/pull/11467#discussion_r1645029522


##########
hudi-common/src/main/avro/HoodieMetadata.avsc:
##########
@@ -427,6 +427,15 @@
                             "type": "int",
                             "default": 0,
                             "doc": "Represents fileId encoding. Possible 
values are 0 and 1. O represents UUID based fileID, and 1 represents raw string 
format of the fileId. \nWhen the encoding is 0, reader can deduce fileID from 
fileIdLowBits, fileIdHighBits and fileIndex."
+                        },
+                        {
+                            "name": "position",
+                            "type": [
+                                "null",
+                                "long"
+                            ],
+                            "default": null,

Review Comment:
   Should we instead have adefault of `-1L`? cc @yihua @nsivabalan 
   That's what we use in `HoodieRecordLocation` - 
https://github.com/apache/hudi/blob/9f0130442a502bff6d6f7a649a7808a03d51da41/hudi-common/src/main/java/org/apache/hudi/common/model/HoodieRecordLocation.java#L46



##########
hudi-common/src/main/java/org/apache/hudi/metadata/HoodieMetadataPayload.java:
##########
@@ -156,6 +156,7 @@ public class HoodieMetadataPayload implements 
HoodieRecordPayload<HoodieMetadata
   public static final String RECORD_INDEX_FIELD_FILEID_ENCODING = 
"fileIdEncoding";
   public static final int RECORD_INDEX_FIELD_FILEID_ENCODING_UUID = 0;
   public static final int RECORD_INDEX_FIELD_FILEID_ENCODING_RAW_STRING = 1;
+  public static final String RECORD_INDEX_POSITION = "position";

Review Comment:
   rename to `RECORD_INDEX_FIELD_POSITION` to be consistent with other names 
above



##########
hudi-common/src/main/java/org/apache/hudi/metadata/HoodieMetadataPayload.java:
##########
@@ -797,7 +800,8 @@ public static HoodieRecord<HoodieMetadataPayload> 
createRecordIndexUpdate(String
               fileIndex,
               "",
               instantTimeMillis,
-              0));
+              0,
+              null));

Review Comment:
   note: might change if we decide to use -1 as default



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

Reply via email to