GitHub user jinxing64 opened a pull request: https://github.com/apache/spark/pull/16503
[SPARK-18113] Method canCommit should return the same value when call⦠â¦ed by the same attempt multi times. ## What changes were proposed in this pull request? Method canCommit sends AskPermissionToCommitOutput using askWithRetry. If timeout, it will send again. Thus AskPermissionToCommitOutput can be received multi times. Method canCommit should return the same value when called by the same attempt multi times. In implementation before this fix, method handleAskPermissionToCommit just check if there is committer already registered, which is not enough. When worker retries AskPermissionToCommitOutput it will get CommitDeniedException, then the task will fail with reason TaskCommitDenied, which is not regarded as a task failure(SPARK-11178), so TaskScheduler will schedule this task infinitely. In this fix OutputCommitCoordinator also checks whether the attemptNumber in AskPermissionToCommit is the same with registered committer. ## How was this patch tested? Added a new unit test to OutputCommitCoordinatorSuite. You can merge this pull request into a Git repository by running: $ git pull https://github.com/jinxing64/spark SPARK-18113 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/spark/pull/16503.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #16503 ---- commit 43a01ebc76f3483aa585815e709309380159cd5c Author: jinxing <jinx...@meituan.com> Date: 2017-01-08T16:10:26Z [SPARK-18113] Method canCommit should return the same value when called by the same attempt multi times. ---- --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org