KevinSmile edited a comment on pull request #29653: URL: https://github.com/apache/spark/pull/29653#issuecomment-687820291
@srowen Currently, when you do `run-example`, `SparkSubmitCommandBuilder` will auto add `--jars` (set to all jars in `examples/jars` folder) for you. https://github.com/apache/spark/blob/f5360e761ef161f7e04526b59a4baf53f1cf8cd5/launcher/src/main/java/org/apache/spark/launcher/SparkSubmitCommandBuilder.java#L215-L217 However, `--jars` is different from `<application-jar>` (aka primaryResource, which contains your Main-Class) . So when it (in standalone cluster mode) goes to: https://github.com/apache/spark/blob/32d87c2b595b4aac2d9274424a43697299638f61/core/src/main/scala/org/apache/spark/deploy/SparkSubmit.scala#L695-L696 https://github.com/apache/spark/blob/f55694638d45f34ab91f6f6ec2066cbf7631f4af/core/src/main/scala/org/apache/spark/deploy/ClientArguments.scala#L74-L89 We get the error described in [SPARK-32804]: 1. Missing primaryResource arg. ====> aka `<application-jar>` 2. Wrong appResource arg. ====> "spark-internal" should not be set as an arg in `run-example` Actually, in [SPARK-32804], "spark-internal" is treated as primaryResource  (But client mode does not have the problem, as it has a different logic.) I would say it's kind of tricky...... ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
