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 2018/12/19 16:24:36 UTC

[GitHub] aljoscha commented on a change in pull request #7313: [FLINK-11116][fs-connector] Removed randomness from HDFS and Local fs writers.

aljoscha commented on a change in pull request #7313: [FLINK-11116][fs-connector] Removed randomness from HDFS and Local fs writers.
URL: https://github.com/apache/flink/pull/7313#discussion_r242982233
 
 

 ##########
 File path: flink-filesystems/flink-hadoop-fs/src/main/java/org/apache/flink/runtime/fs/hdfs/HadoopRecoverableWriter.java
 ##########
 @@ -60,6 +60,12 @@ public HadoopRecoverableWriter(org.apache.hadoop.fs.FileSystem fs) {
 	@Override
 	public RecoverableFsDataOutputStream open(Path filePath) throws IOException {
 		final org.apache.hadoop.fs.Path targetFile = HadoopFileSystem.toHadoopPath(filePath);
+
+		// the finalized part must not exist already
+		if (fs.exists(targetFile)) {
 
 Review comment:
   Maybe put a more elaborate exception message that indicates that this is a bug. Because I think this shouldn't happen or you're in some deeper problem

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services