I have written a Java program for Spark. But how to run and compile it from Unix command line. Do I have to include any jar while compiling for running
I had the same question a few days ago and yesterday managed to solve it.
That's what I've done:
sbt packageSPARK_HOME_DIR/sbin/spark_master.sh localhost:8080 and make sure your server is running. Copy link from URL (from server description, not localhost. It shoul be something with port 7077 or similiar)SPARK_HOME_DIR/bin/spark-class org.apache.spark.deploy.worker.Worker spark://IP:PORT where IP:PORT is the URL copied in 6SPARK_HOME_DIR/bin/spark-submit --class "SimpleApp" --master URL target/scala-2.10/simple-project_2.10-1.0.jarThat's worked for me and hope will help you.
Pawel