mridulm commented on a change in pull request #34366:
URL: https://github.com/apache/spark/pull/34366#discussion_r742974924



##########
File path: 
resource-managers/yarn/src/main/scala/org/apache/spark/deploy/yarn/Client.scala
##########
@@ -1277,10 +1277,14 @@ private[spark] class Client(
     } else {
       val YarnAppReport(appState, finalState, diags) = 
monitorApplication(appId)
       if (appState == YarnApplicationState.FAILED || finalState == 
FinalApplicationStatus.FAILED) {
+        var amContainerSuccess = false
         diags.foreach { err =>
+          amContainerSuccess = err.contains("AM Container") && 
err.contains("exitCode: 0")
           logError(s"Application diagnostics message: $err")
         }
-        throw new SparkException(s"Application $appId finished with failed 
status")
+        if (!amContainerSuccess) {
+          throw new SparkException(s"Application $appId finished with failed 
status")
+        }

Review comment:
       Thanks for the details @AngersZhuuuu, this is unfortunate.
   I wanted to avoid parsing from diagnostic, given it is potentially brittle - 
without timeline service, I am not sure how to extract this without parsing the 
string.
   And thoughts @tgravescs ?




-- 
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]

Reply via email to