You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2022/05/11 05:44:19 UTC

[GitHub] [flink-table-store] tsreaper commented on a diff in pull request #107: [FLINK-27372] Make DataFileMeta and ManifestFileMeta schemaless

tsreaper commented on code in PR #107:
URL: https://github.com/apache/flink-table-store/pull/107#discussion_r869889027


##########
flink-table-store-core/src/main/java/org/apache/flink/table/store/file/data/DataFileMetaSerializer.java:
##########
@@ -48,27 +42,25 @@ public RowData toRow(DataFileMeta meta) {
                 StringData.fromString(meta.fileName()),
                 meta.fileSize(),
                 meta.rowCount(),
-                meta.minKey(),
-                meta.maxKey(),
-                keyStatsArraySerializer.toRow(meta.keyStats()),
-                valueStatsArraySerializer.toRow(meta.valueStats()),
+                serializeBinaryRow(meta.minKey()),

Review Comment:
   Current implementation will copy `BinaryRowData` into a new byte array. Can we keep `BinaryRowData` and read its underlying byte array directly when serializing? This can be applied not only to `minKey` and `maxKey`, but also to `partitionKey` and even `BinaryTableStats`. Also by storing a `BinaryRowData` in the object we can read its fields directly if we know the types, which simplifies the implementation a lot.



-- 
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@flink.apache.org

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