You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "dongjoon-hyun (via GitHub)" <gi...@apache.org> on 2023/02/06 18:21:06 UTC

[GitHub] [spark] dongjoon-hyun commented on a diff in pull request #39900: [SPARK-42357][CORE] Log `exitCode` when `SparkContext.stop` starts

dongjoon-hyun commented on code in PR #39900:
URL: https://github.com/apache/spark/pull/39900#discussion_r1097762150


##########
core/src/main/scala/org/apache/spark/SparkContext.scala:
##########
@@ -2092,6 +2092,7 @@ class SparkContext(config: SparkConf) extends Logging {
    * @param exitCode Specified exit code that will passed to scheduler backend in client mode.
    */
   def stop(exitCode: Int): Unit = {
+    logInfo(s"SparkContext is stopping with exitCode $exitCode.")
     if (LiveListenerBus.withinListenerThread.value) {
       throw new SparkException(s"Cannot stop SparkContext within listener bus thread.")
     }

Review Comment:
   Thank you for reviewing. I also consider that and this ways, but I want to be clear that this log is a marker of this method itself. So, it should be at the first line of the method before Spark doing anything.



-- 
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: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org