-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Conversation
|
I do not understand what this PR does. Does this pull request fix that SparkException or cause it? Is this a problem using Spark 2.2 and What engine template does this occur for? |
|
Also, this PR is from |
|
This doesn’t look like a valid PR. @561152 are you looking to report an issue? Please do so by filing a JIRA following instructions at http://predictionio.incubator.apache.org/community/contribute-code/#how-to-report-an-issue |
|
@mars @dszeto thanks,I do not know much about GitHub, please understand pio batchpredict :error reporting [ERROR] [TaskSetManager] Task 0 in stage 0.0 failed 1 times; aborting job test three: |
Git URLs still pending updates
|
Is it possible to move JIRA and close this pull request? |
|
Sounds good @takezoe, though I am still unclear what this issue really is. |
|
I also agree with takezoe! @mars |
|
@shimamoto yes, it requires two SparkContexts because PredictionIO implicitly stops the first one after preparing deploy, so it cannot be reused for the second instance to run queries. I don’t understand what causes this error here, as the two SparkContexts normally work correctly. |
@mars Oh, I see. But when using a persisted model, PredictionIO don't stop the first SparkContext. I guess this causes, for example, if we use the Recommendation Engine Template, which supports loading a persisted model (see). |
|
@shimamoto Ah, this makes so much sense now 😲 Not sure of a solution, yet. I created a JIRA for this issue: PIO-138 Batch predict fails when using a PersistentModel. Let's continue discussion for a fix there. |
|
Is there a way to close this issue other than commit message? |
|
@takezoe Unfortunately we can only close PRs with a commit message at this point. Gitbox may help but it has not been working for me. |
|
@dszeto I see. I found an empty commit to close PRs: apache/spark@f217d7d |
Closes #441
pio batchpredict --input /tmp/pio/batchpredict-input.json --output /tmp/pio/batchpredict-output.json
[WARN] [ALSModel] Product factor is not cached. Prediction could be slow.
Exception in thread "main" org.apache.spark.SparkException: Only one SparkContext may be running in this JVM (see SPARK-2243). To ignore this error, set spark.driver.allowMultipleContexts = true. The currently running SparkContext was created at:
org.apache.spark.SparkContext.(SparkContext.scala:76)
org.apache.predictionio.workflow.WorkflowContext$.apply(WorkflowContext.scala:45)
org.apache.predictionio.workflow.BatchPredict$.run(BatchPredict.scala:160)
org.apache.predictionio.workflow.BatchPredict$$anonfun$main$1$$anonfun$apply$2.apply(BatchPredict.scala:121)
org.apache.predictionio.workflow.BatchPredict$$anonfun$main$1$$anonfun$apply$2.apply(BatchPredict.scala:117)
scala.Option.map(Option.scala:146)
org.apache.predictionio.workflow.BatchPredict$$anonfun$main$1.apply(BatchPredict.scala:117)
org.apache.predictionio.workflow.BatchPredict$$anonfun$main$1.apply(BatchPredict.scala:115)
scala.Option.map(Option.scala:146)
org.apache.predictionio.workflow.BatchPredict$.main(BatchPredict.scala:115)
org.apache.predictionio.workflow.BatchPredict.main(BatchPredict.scala)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
java.lang.reflect.Method.invoke(Method.java:498)
org.apache.spark.deploy.SparkSubmit$.org$apache$spark$deploy$SparkSubmit$$runMain(SparkSubmit.scala:738)
org.apache.spark.deploy.SparkSubmit$.doRunMain$1(SparkSubmit.scala:187)
org.apache.spark.deploy.SparkSubmit$.submit(SparkSubmit.scala:212)
org.apache.spark.deploy.SparkSubmit$.main(SparkSubmit.scala:126)
org.apache.spark.deploy.SparkSubmit.main(SparkSubmit.scala)
at org.apache.spark.SparkContext$$anonfun$assertNoOtherContextIsRunning$2.apply(SparkContext.scala:2278)
at org.apache.spark.SparkContext$$anonfun$assertNoOtherContextIsRunning$2.apply(SparkContext.scala:2274)
at scala.Option.foreach(Option.scala:257)
at org.apache.spark.SparkContext$.assertNoOtherContextIsRunning(SparkContext.scala:2274)
at org.apache.spark.SparkContext$.markPartiallyConstructed(SparkContext.scala:2353)
at org.apache.spark.SparkContext.(SparkContext.scala:85)
at org.apache.predictionio.workflow.WorkflowContext$.apply(WorkflowContext.scala:45)
at org.apache.predictionio.workflow.BatchPredict$.run(BatchPredict.scala:183)
at org.apache.predictionio.workflow.BatchPredict$$anonfun$main$1$$anonfun$apply$2.apply(BatchPredict.scala:121)
at org.apache.predictionio.workflow.BatchPredict$$anonfun$main$1$$anonfun$apply$2.apply(BatchPredict.scala:117)
at scala.Option.map(Option.scala:146)
at org.apache.predictionio.workflow.BatchPredict$$anonfun$main$1.apply(BatchPredict.scala:117)
at org.apache.predictionio.workflow.BatchPredict$$anonfun$main$1.apply(BatchPredict.scala:115)
at scala.Option.map(Option.scala:146)
at org.apache.predictionio.workflow.BatchPredict$.main(BatchPredict.scala:115)
at org.apache.predictionio.workflow.BatchPredict.main(BatchPredict.scala)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.spark.deploy.SparkSubmit$.org$apache$spark$deploy$SparkSubmit$$runMain(SparkSubmit.scala:738)
at org.apache.spark.deploy.SparkSubmit$.doRunMain$1(SparkSubmit.scala:187)
at org.apache.spark.deploy.SparkSubmit$.submit(SparkSubmit.scala:212)
at org.apache.spark.deploy.SparkSubmit$.main(SparkSubmit.scala:126)
at org.apache.spark.deploy.SparkSubmit.main(SparkSubmit.scala)