xushiyan commented on code in PR #18212:
URL: https://github.com/apache/hudi/pull/18212#discussion_r2838505213


##########
hudi-flink-datasource/hudi-flink/src/main/java/org/apache/hudi/source/split/HoodieSourceSplitSerializer.java:
##########
@@ -82,6 +83,21 @@ public byte[] serialize(HoodieSourceSplit obj) throws 
IOException {
       // Serialize fileOffset
       out.writeInt(obj.getFileOffset());
 
+      // Serialize instant range (Option<InstantRange>)
+      out.writeBoolean(obj.getInstantRange().isPresent());
+      if (obj.getInstantRange().isPresent()) {
+        InstantRange instantRange = obj.getInstantRange().get();
+        out.writeBoolean(instantRange.getStartInstant().isPresent());
+        if (instantRange.getStartInstant().isPresent()) {
+          out.writeUTF(instantRange.getStartInstant().get());
+        }
+        out.writeBoolean(instantRange.getEndInstant().isPresent());
+        if (instantRange.getEndInstant().isPresent()) {
+          out.writeUTF(instantRange.getEndInstant().get());
+        }
+        out.writeUTF(InstantRange.getRangeType(instantRange).name());

Review Comment:
   the class is newly added for flink source v2 right? then this is ok, 
otherwise, version needs to be incremented



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