jt2594838 commented on a change in pull request #388: [IOTDB-200] Support creating TsFileWriter with config of storage file system URL: https://github.com/apache/incubator-iotdb/pull/388#discussion_r323595178
########## File path: tsfile/src/main/java/org/apache/iotdb/tsfile/write/writer/TsFileIOWriter.java ########## @@ -120,7 +124,11 @@ public TsFileIOWriter(TsFileOutput output) throws IOException { */ public TsFileIOWriter(TsFileOutput out, List<ChunkGroupMetaData> chunkGroupMetaDataList) throws IOException { - this.out = out; + if (config.getTSFileStorageFs().equals(FSType.HDFS)) { + this.out = new HDFSOutput(file.getPath(), false); //NOTE overwrite false here + } else { + this.out = new DefaultTsFileOutput(file); + } Review comment: Maybe you can use your `FileOutputFactory` as you have done elsewhere. ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services