pvary commented on code in PR #14880:
URL: https://github.com/apache/iceberg/pull/14880#discussion_r2634133876


##########
flink/v2.1/flink/src/main/java/org/apache/iceberg/flink/sink/dynamic/DynamicRecordInternalSerializer.java:
##########
@@ -68,7 +81,11 @@ public void serialize(DynamicRecordInternal toSerialize, 
DataOutputView dataOutp
     dataOutputView.writeUTF(toSerialize.tableName());
     dataOutputView.writeUTF(toSerialize.branch());
     if (writeSchemaAndSpec) {
-      dataOutputView.writeUTF(SchemaParser.toJson(toSerialize.schema()));
+      if (writeLongUTF) {
+        SerializerHelper.writeLongUTF(dataOutputView, 
SchemaParser.toJson(toSerialize.schema()));
+      } else {
+        dataOutputView.writeUTF(SchemaParser.toJson(toSerialize.schema()));
+      }

Review Comment:
   nit: newline



##########
flink/v2.1/flink/src/main/java/org/apache/iceberg/flink/sink/dynamic/DynamicRecordInternalSerializer.java:
##########
@@ -152,7 +173,11 @@ public DynamicRecordInternal 
deserialize(DynamicRecordInternal reuse, DataInputV
     final PartitionSpec spec;
     final RowDataSerializer rowDataSerializer;
     if (writeSchemaAndSpec) {
-      schema = SchemaParser.fromJson(dataInputView.readUTF());
+      if (writeLongUTF) {
+        schema = 
SchemaParser.fromJson(SerializerHelper.readLongUTF(dataInputView));
+      } else {
+        schema = SchemaParser.fromJson(dataInputView.readUTF());
+      }

Review Comment:
   nit: newline



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