steveloughran commented on code in PR #4303:
URL: https://github.com/apache/hadoop/pull/4303#discussion_r873643599
##########
hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/output/FileOutputCommitter.java:
##########
@@ -163,7 +168,11 @@ public FileOutputCommitter(Path outputPath,
this.outputPath = fs.makeQualified(outputPath);
}
}
-
+
+ private static void setJobPendingDirName(JobContext context) {
+ JOB_PENDING_DIR_NAME = "_temporary_" + context.getJobID();
Review Comment:
there's an assumption here that the job ID is always unique. this doesn''t
hold for all spark versions. SPARK-33402
##########
hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/output/FileOutputCommitter.java:
##########
@@ -57,6 +57,8 @@ public class FileOutputCommitter extends PathOutputCommitter {
* committed yet.
*/
public static final String PENDING_DIR_NAME = "_temporary";
+
+ public static String JOB_PENDING_DIR_NAME = "_temporary";
Review Comment:
this doesn't actually work if you have multiple jobs running in the same
process, which exactly spark drivers do. if job 2 starts while job 1 is active,
job 1 will be pointed at the job2 temp dir. as a result, it will only commit
those tasks which generate work after that switch, and not even notice a problem
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]