GitHub user mengxr opened a pull request:

    https://github.com/apache/spark/pull/9675

    [SPARK-11709] include call site info in SparkContext.assertNotStopped error 
message

    This helps debug issues caused by multiple SparkContext instances. 
@JoshRosen  
    
    ~~~
    scala> sc.stop()
    
    scala> sc.parallelize(0 until 10)
    java.lang.IllegalStateException: Cannot call methods on a stopped 
SparkContext.
    This stopped SparkContext was created at:
    
    org.apache.spark.SparkContext.<init>(SparkContext.scala:82)
    org.apache.spark.repl.SparkILoop.createSparkContext(SparkILoop.scala:1017)
    $iwC$$iwC.<init>(<console>:9)
    $iwC.<init>(<console>:18)
    <init>(<console>:20)
    .<init>(<console>:24)
    .<clinit>(<console>)
    .<init>(<console>:7)
    .<clinit>(<console>)
    $print(<console>)
    sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    java.lang.reflect.Method.invoke(Method.java:606)
    org.apache.spark.repl.SparkIMain$ReadEvalPrint.call(SparkIMain.scala:1065)
    org.apache.spark.repl.SparkIMain$Request.loadAndRun(SparkIMain.scala:1340)
    org.apache.spark.repl.SparkIMain.loadAndRunReq$1(SparkIMain.scala:840)
    org.apache.spark.repl.SparkIMain.interpret(SparkIMain.scala:871)
    org.apache.spark.repl.SparkIMain.interpret(SparkIMain.scala:819)
    org.apache.spark.repl.SparkILoop.reallyInterpret$1(SparkILoop.scala:857)
    
    The active context was created at:
    
    (No active SparkContext.)
    ~~~

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/mengxr/spark SPARK-11709

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/9675.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 #9675
    
----
commit d66579667d3423e7402c71ff33138cbc95114a4d
Author: Xiangrui Meng <m...@databricks.com>
Date:   2015-11-12T20:07:51Z

    include call site info in SparkContext.assertNotStopped error message

----


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

Reply via email to