zhangjun0x01 commented on code in PR #1500:
URL: https://github.com/apache/incubator-paimon/pull/1500#discussion_r1254222520
##########
paimon-core/src/main/java/org/apache/paimon/io/KeyValueFileWriterFactory.java:
##########
@@ -90,11 +97,21 @@ public DataFilePathFactory pathFactory() {
}
public RollingFileWriter<KeyValue, DataFileMeta>
createRollingMergeTreeFileWriter(int level) {
+ updateFormatByLevel(level);
return new RollingFileWriter<>(
() -> createDataFileWriter(pathFactory.newPath(), level,
getCompression(level)),
suggestedFileSize);
}
+ private void updateFormatByLevel(int level) {
+ String fileFormat = levelFormats.get(level);
+ if (null != fileFormat) {
+ pathFactory.setFormatIdentifier(fileFormat);
Review Comment:
I udpate it by construct a new `DataFilePathFactory`
--
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]