gorillalabs / sparkling-getting-started

A companion repo to the sparkling getting started guide
http://gorillalabs.github.io/sparkling/articles/getting_started.html
19 stars 9 forks source link

ExceptionInInitializerError #2

Closed alandipert closed 9 years ago

alandipert commented 9 years ago

Hello, When I run:

$ lein uberjar
$ java -jar target/sparkling-getting-started-1.0.0-SNAPSHOT-standalone.jar

I get an error like this:

Exception in thread "main" java.lang.ExceptionInInitializerError
...
Caused by: java.lang.ClassNotFoundException: org.apache.spark.SparkConf

Is there a configuration or compilation step I'm missing or is this a bug?

I'm on Linux with openjdk 1.8.0_40, Leiningen 2.5.1. Thanks for any help!

chrisbetz commented 9 years ago

Hi Alan,

sorry for taking so long. I’m not quite sure what you’re up to. In order to run locally, you need to have a spark dependency which is missing in your case. The „normal“ config of sparkling is for running on a cluster, where spark or a spark assembly jar usually is provided (see ).

So, in order to get you up and running, you should add [org.apache.spark/spark-core_2.10 "1.2.1"] together with whatever dependency is necessary for your code. Or use the spark-assembly from your distribution, if you’re using on on your cluster.

Good luck!

Chris

Am 04.05.2015 um 22:04 schrieb Alan Dipert notifications@github.com:

Hello, When I run:

$ lein uberjar $ java -jar target/sparkling-getting-started-1.0.0-SNAPSHOT-standalone.jar I get an error like this:

Exception in thread "main" java.lang.ExceptionInInitializerError ... Caused by: java.lang.ClassNotFoundException: org.apache.spark.SparkConf Is there a configuration or compilation step I'm missing or is this a bug?

I'm on Linux with openjdk 1.8.0_40, Leiningen 2.5.1. Thanks for any help!

— Reply to this email directly or view it on GitHub https://github.com/gorillalabs/sparkling-getting-started/issues/2.

alandipert commented 9 years ago

Hey, thank you for your help with this! We figured it out.

octplane commented 8 years ago

Me being a real spark newbie, let me thank you for this :+1:

chrisbetz commented 8 years ago

Oh, you're welcome. :)

On Wed, Nov 11, 2015 at 9:42 PM, Pierre Baillet notifications@github.com wrote:

Me being a real spark newbie, let me thank you for this [image: :+1:]

— Reply to this email directly or view it on GitHub https://github.com/gorillalabs/sparkling-getting-started/issues/2#issuecomment-155904146 .