rdblue commented on a change in pull request #14: Pluggable file I/O submodule in TableOperations URL: https://github.com/apache/incubator-iceberg/pull/14#discussion_r240438110
########## File path: core/src/test/java/com/netflix/iceberg/LocalTableOperations.java ########## @@ -52,25 +53,19 @@ public void commit(TableMetadata base, TableMetadata metadata) { } @Override - public InputFile newInputFile(String path) { - return localInput(path); - } - - @Override - public OutputFile newMetadataFile(String filename) { - try { - File metadataFile = temp.newFile(filename); - metadataFile.delete(); - metadataFile.deleteOnExit(); - return Files.localOutput(metadataFile); - } catch (IOException e) { - throw new RuntimeIOException(e); - } + public FileIO io() { + return io; } @Override - public void deleteFile(String path) { - new File(path).delete(); + public String metadataFileLocation(String fileName) { + return createdMetadataFilePaths.computeIfAbsent(fileName, name -> { + try { + return temp.newFile(name).getAbsolutePath(); Review comment: Shouldn't this still run delete() and deleteOnExit()? ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on 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