xuanyuanking commented on a change in pull request #24110: [SPARK-25341][Core]
Support rolling back a shuffle map stage and re-generate the shuffle files
URL: https://github.com/apache/spark/pull/24110#discussion_r272062089
##########
File path: core/src/main/scala/org/apache/spark/TaskContext.scala
##########
@@ -176,6 +176,17 @@ abstract class TaskContext extends Serializable {
*/
def getLocalProperty(key: String): String
+ /**
+ * The indeterminate attempt ID of the stage that this task belongs to, it
returns the stage
+ * attempt number while the stage is not determinate and returns none on the
contrary.
+ */
+ def indeterminateStageAttemptId(shuffleId: Int): Option[Int] = {
+ val id =
getLocalProperty(SparkContext.INDETERMINATE_STAGE_ATTEMPT_ID_PREFIX + shuffleId)
Review comment:
I think we should include shuffle id here, for an indeterminate shuffle map
task which parent stage also indeterminate, we both need parent stage id and
current id here for shuffle reader and writer. Also for the more complex
scenario, for join/cogroup operation, maybe we have more indeterminate parents
for single shuffle map stage.
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]