Ilya Ganelin created SPARK-6616: ----------------------------------- Summary: IsStopped set to true in before stop() is complete. Key: SPARK-6616 URL: https://issues.apache.org/jira/browse/SPARK-6616 Project: Spark Issue Type: Improvement Components: Spark Core Affects Versions: 1.3.0 Reporter: Ilya Ganelin
There are numerous instances throughout the code base of the following: ``` if (!stopped) { stopped = true ... } ``` In general, this is bad practice since it can cause an incomplete cleanup if there is an error during shutdown and not all code executes. Incomplete cleanup is harder to track down than a double cleanup that triggers some error. I propose fixing this throughout the code, starting with the cleanup sequence with ```SparkContext.stop()```. A cursory examination reveals this in ```SparkContext.stop(), SparkEnv.stop(), and ContextCleaner.stop()```. -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org