Github user vanzin commented on the pull request:
https://github.com/apache/spark/pull/987#issuecomment-45292958
Ok, in cluster mode you can't use SparkConf.set(), but the other two
options work fine. You can't do System.setProperty() in cluster mode to achieve
that either, so even with your patch, you'd have to use -DSPARK_JAR=foo in the
command line for it to work in yarn-cluster mode.
---
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 [email protected] or file a JIRA ticket
with INFRA.
---