You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@paimon.apache.org by "JingsongLi (via GitHub)" <gi...@apache.org> on 2024/03/18 02:22:12 UTC

Re: [PR] [Flink] Fix Multibyte Character Encoding in MultiTableCommittable Serialization [incubator-paimon]

JingsongLi commented on code in PR #3028:
URL: https://github.com/apache/incubator-paimon/pull/3028#discussion_r1527693828


##########
paimon-flink/paimon-flink-common/src/main/java/org/apache/paimon/flink/sink/MultiTableCommittableSerializer.java:
##########
@@ -83,17 +84,18 @@ public MultiTableCommittable deserialize(int committableVersion, byte[] bytes)
         int databaseLen = buffer.getInt();
         byte[] databaseBytes = new byte[databaseLen];
         buffer.get(databaseBytes, 0, databaseLen);
-        String database = new String(databaseBytes);
+        String database = new String(databaseBytes,StandardCharsets.UTF_8);

Review Comment:
   `database.getBytes()` should use `database.getBytes(UTF_8)` too.



-- 
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: issues-unsubscribe@paimon.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org