Skip to content

Conversation

@lianhuiwang
Copy link
Contributor

when spark.yarn.user.classpath.first=true and using 'spark-submit --jars hdfs://user/foo.jar', it can not put foo.jar to system classpath. so we need to put yarn's linkNames of jars to the system classpath. @vanzin @tgravescs

@SparkQA
Copy link

SparkQA commented Oct 9, 2015

Test build #43466 has finished for PR 9045 at commit 3023e1e.

  • This patch fails Scala style tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

classpath is already printed if you turn debug on.

@tgravescs
Copy link
Contributor

I don't quite follow the scenario can you please describe in more detail?

@SparkQA
Copy link

SparkQA commented Oct 9, 2015

Test build #43472 has finished for PR 9045 at commit 4c5290a.

  • This patch fails to build.
  • This patch merges cleanly.
  • This patch adds no public classes.

@vanzin
Copy link
Contributor

vanzin commented Oct 9, 2015

Not sure I understand either. What is this addJars you talk about? Also, the code doesn't even build.

@lianhuiwang
Copy link
Contributor Author

@vanzin @tgravescs when spark-submit --master yarn-cluster --jars /users/xxx.jar and spark.yarn.user.classpath.first=true, the jars of the command are not in system's classpath.
so when schemes of jars are not LOCAL_SCHEME and fileName is null, it needs to add yarn's linkNames of jars to classpath.

@SparkQA
Copy link

SparkQA commented Oct 10, 2015

Test build #43530 has finished for PR 9045 at commit 6f395d6.

  • This patch fails MiMa tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@tgravescs
Copy link
Contributor

sorry your description isn't clarifying it for me. Could you perhaps give an example? what do you mean by linkNames?

If I use --jars /users/foo.jar and spark.yarn.user.classpath.first=true. foo.jar gets put into the system classpath (CLASSPATH=.....:foo.jar:...:spark.jar

@lianhuiwang
Copy link
Contributor Author

@tgravescs if use --jars hdfs://users/foo.jar, now i can not put foo.jar into the system classpath without this PR.

@tgravescs
Copy link
Contributor

ah I understand now, thanks. I'll take a look

@vanzin
Copy link
Contributor

vanzin commented Oct 12, 2015

@lianhuiwang can you update the description to match your explanation? Mentioning "addJars" is confusing because it's not the source of the problem at all - rather, spark-submit's "--jars" option is.

@vanzin
Copy link
Contributor

vanzin commented Oct 12, 2015

retest this please

@SparkQA
Copy link

SparkQA commented Oct 12, 2015

Test build #43578 has finished for PR 9045 at commit 6f395d6.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@vanzin
Copy link
Contributor

vanzin commented Oct 12, 2015

LGTM pending update of the description.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minor nit, add space before {

@tgravescs
Copy link
Contributor

LGTM too, thanks for catching this, I should have tested these when I fixed the other part.

@lianhuiwang lianhuiwang changed the title [spark-11026][yarn]spark.yarn.user.classpath.first doesn't work for remote addJars [spark-11026][yarn]when using 'spark-submit --jars hdfs://user/foo.jar' and spark.yarn.user.classpath.first=true, it doesn't put foo.jar to system classpath Oct 13, 2015
@lianhuiwang lianhuiwang changed the title [spark-11026][yarn]when using 'spark-submit --jars hdfs://user/foo.jar' and spark.yarn.user.classpath.first=true, it doesn't put foo.jar to system classpath [spark-11026][yarn]spark.yarn.user.classpath.first does work for 'spark-submit --jars hdfs://user/foo.jar' Oct 13, 2015
@lianhuiwang
Copy link
Contributor Author

@tgravescs @vanzin i have updated it. thanks.

@SparkQA
Copy link

SparkQA commented Oct 13, 2015

Test build #43642 has finished for PR 9045 at commit d4049a7.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@tgravescs
Copy link
Contributor

+1 thanks!

asfgit pushed a commit that referenced this pull request Oct 13, 2015
…park-submit --jars hdfs://user/foo.jar'

when spark.yarn.user.classpath.first=true and using 'spark-submit --jars hdfs://user/foo.jar', it can not put foo.jar to system classpath. so we need to put yarn's linkNames of jars to the system classpath. vanzin tgravescs

Author: Lianhui Wang <[email protected]>

Closes #9045 from lianhuiwang/spark-11026.

(cherry picked from commit 626aab7)
Signed-off-by: Tom Graves <[email protected]>
@asfgit asfgit closed this in 626aab7 Oct 13, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants