xuanyuanking commented on a change in pull request #24892: [SPARK-25341][Core]
Support rolling back a shuffle map stage and re-generate the shuffle files
URL: https://github.com/apache/spark/pull/24892#discussion_r295732974
##########
File path: core/src/main/scala/org/apache/spark/TaskContext.scala
##########
@@ -183,6 +183,17 @@ abstract class TaskContext extends Serializable {
@Evolving
def resources(): Map[String, ResourceInformation]
+ /**
+ * The shuffle generation 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 getShuffleGenerationId(shuffleId: Int): Option[Int] = {
Review comment:
Yeah, thanks for the advice, compared with using Option in Java code, I
change all places to use -1. Done in 5a4b8b8.
----------------------------------------------------------------
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]