Github user tgravescs commented on a diff in the pull request:
https://github.com/apache/spark/pull/21606#discussion_r197545709
--- Diff:
core/src/main/scala/org/apache/spark/internal/io/SparkHadoopWriter.scala ---
@@ -76,13 +76,17 @@ object SparkHadoopWriter extends Logging {
// Try to write all RDD partitions as a Hadoop OutputFormat.
try {
val ret = sparkContext.runJob(rdd, (context: TaskContext, iter:
Iterator[(K, V)]) => {
+ // SPARK-24552: Generate a unique "attempt ID" based on the stage
and task atempt numbers.
+ // Assumes that there won't be more than Short.MaxValue attempts,
at least not concurrently.
+ val attemptId = (context.stageAttemptNumber << 16) |
context.attemptNumber
--- End diff --
the problem is that taskid is a long, we can't change the hadoop api for
that, and to me its more possible to have a valid task id > 2^32. It might
not be ideal to do it this way but I think its a good bug fix especially for
now, we can file a follow on to improve if we have ideas or want to change
interface
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]