Exercise 12 - Setup spark on PC and also integrate spark with existing project

sbt
eclipse
apache-spark
scala
#1

Problem:

  • Download and install spark (make sure environment variables are set)
  • Run simple spark program using spark-shell - Create list and use parallelize and print

val i = List(1, 2, 3, 4)
sc.parallelize(i).collect().foreach(println)

  • Define dependencies in build.sbt for the existing project

libraryDependencies += “org.apache.spark” % “spark-core_2.11” % “1.6.2”

  • Run sbt package and sbt eclipse

Please provide the output for

  • spark program executed in spark-shell
  • contents of build.sbt and .classparth
0 Likes

#2

build.sbt
name := "hw"
version := "1.0"
scalaVersion := "2.12.1"
libraryDependencies += “org.apache.spark” % “spark-core_2.11” % “1.6.2”

<classpath>
  <classpathentry kind="src" path="src\main\scala"/>
  <classpathentry kind="con" path="org.scala-ide.sdt.launching.SCALA_CONTAINER"/>
  <classpathentry kind="lib" path="C:\Users\nagella.shyam\.ivy2\cache\org.apache.spark\spark-core_2.11\jars\spark-core_2.11-1.6.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\nagella.shyam\.ivy2\cache\org.apache.avro\avro-mapred\jars\avro-mapred-1.7.7-hadoop2.jar"/>
  <classpathentry kind="lib" path="C:\Users\nagella.shyam\.ivy2\cache\org.apache.avro\avro-ipc\jars\avro-ipc-1.7.7-tests.jar"/>
  <classpathentry kind="lib" path="C:\Users\nagella.shyam\.ivy2\cache\org.apache.avro\avro-ipc\jars\avro-ipc-1.7.7.jar"/>

SparkProgram

scala> val i=List(1,2,3,4)
i: List[Int] = List(1, 2, 3, 4)

scala> sc.parallelize(i).collect.foreach(println)
1
2
3
4

0 Likes

#3

scala> val i = List(1,2,3,4)
i: List[Int] = List(1, 2, 3, 4)

scala> sc.parallelize(i).collect().foreach(println)
1
2
3
4

name := "ScalaJdbcConnectSelect"
version := "1.0"
scalaVersion := "2.11.8"
libraryDependencies ++= Seq(“mysql” % “mysql-connector-java” % “5.1.24”,
“org.apache.spark” % “spark-core_2.11” % “1.6.2”
)

<classpath>
  <classpathentry kind="src" path="src\main\scala"/>
  <classpathentry kind="src" path="src\main\resources"/>
  <classpathentry kind="con" path="org.scala-ide.sdt.launching.SCALA_CONTAINER"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\mysql\mysql-connector-java\jars\mysql-connector-java-5.1.24.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.spark\spark-core_2.11\jars\spark-core_2.11-1.6.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.avro\avro-mapred\jars\avro-mapred-1.7.7-hadoop2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.avro\avro-ipc\jars\avro-ipc-1.7.7-tests.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.avro\avro-ipc\jars\avro-ipc-1.7.7.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.avro\avro\jars\avro-1.7.7.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.codehaus.jackson\jackson-core-asl\jars\jackson-core-asl-1.9.13.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.codehaus.jackson\jackson-mapper-asl\jars\jackson-mapper-asl-1.9.13.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.xerial.snappy\snappy-java\bundles\snappy-java-1.1.2.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.commons\commons-compress\jars\commons-compress-1.4.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.tukaani\xz\jars\xz-1.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.slf4j\slf4j-api\jars\slf4j-api-1.7.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.twitter\chill_2.11\jars\chill_2.11-0.5.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.twitter\chill-java\jars\chill-java-0.5.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.esotericsoftware.kryo\kryo\bundles\kryo-2.21.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.esotericsoftware.reflectasm\reflectasm\jars\reflectasm-1.07-shaded.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.esotericsoftware.minlog\minlog\jars\minlog-1.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.objenesis\objenesis\jars\objenesis-1.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.xbean\xbean-asm5-shaded\bundles\xbean-asm5-shaded-4.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-client\jars\hadoop-client-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-common\jars\hadoop-common-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-annotations\jars\hadoop-annotations-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.google.code.findbugs\jsr305\jars\jsr305-1.3.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\commons-cli\commons-cli\jars\commons-cli-1.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.commons\commons-math\jars\commons-math-2.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\xmlenc\xmlenc\jars\xmlenc-0.52.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\commons-httpclient\commons-httpclient\jars\commons-httpclient-3.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\commons-codec\commons-codec\jars\commons-codec-1.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\commons-net\commons-net\jars\commons-net-2.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\log4j\log4j\bundles\log4j-1.2.17.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\commons-lang\commons-lang\jars\commons-lang-2.5.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\commons-configuration\commons-configuration\jars\commons-configuration-1.6.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\commons-collections\commons-collections\jars\commons-collections-3.2.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\commons-digester\commons-digester\jars\commons-digester-1.8.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\commons-beanutils\commons-beanutils\jars\commons-beanutils-1.7.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\commons-beanutils\commons-beanutils-core\jars\commons-beanutils-core-1.8.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.google.protobuf\protobuf-java\bundles\protobuf-java-2.5.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-auth\jars\hadoop-auth-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-hdfs\jars\hadoop-hdfs-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.mortbay.jetty\jetty-util\jars\jetty-util-6.1.26.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-mapreduce-client-app\jars\hadoop-mapreduce-client-app-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-mapreduce-client-common\jars\hadoop-mapreduce-client-common-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-yarn-common\jars\hadoop-yarn-common-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-yarn-api\jars\hadoop-yarn-api-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.slf4j\slf4j-log4j12\jars\slf4j-log4j12-1.7.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.google.inject\guice\jars\guice-3.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\javax.inject\javax.inject\jars\javax.inject-1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\aopalliance\aopalliance\jars\aopalliance-1.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.sonatype.sisu.inject\cglib\jars\cglib-2.2.1-v20090111.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.sun.jersey.jersey-test-framework\jersey-test-framework-grizzly2\jars\jersey-test-framework-grizzly2-1.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.sun.jersey\jersey-server\bundles\jersey-server-1.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\asm\asm\jars\asm-3.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.sun.jersey\jersey-json\bundles\jersey-json-1.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.codehaus.jettison\jettison\bundles\jettison-1.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\stax\stax-api\jars\stax-api-1.0.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.sun.xml.bind\jaxb-impl\jars\jaxb-impl-2.2.3-1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\javax.xml.bind\jaxb-api\jars\jaxb-api-2.2.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\javax.activation\activation\jars\activation-1.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.codehaus.jackson\jackson-jaxrs\jars\jackson-jaxrs-1.8.3.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.codehaus.jackson\jackson-xc\jars\jackson-xc-1.8.3.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.sun.jersey.contribs\jersey-guice\jars\jersey-guice-1.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-yarn-client\jars\hadoop-yarn-client-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-mapreduce-client-core\jars\hadoop-mapreduce-client-core-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-yarn-server-common\jars\hadoop-yarn-server-common-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-mapreduce-client-shuffle\jars\hadoop-mapreduce-client-shuffle-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.hadoop\hadoop-mapreduce-client-jobclient\jars\hadoop-mapreduce-client-jobclient-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.spark\spark-launcher_2.11\jars\spark-launcher_2.11-1.6.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.spark-project.spark\unused\jars\unused-1.0.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.spark\spark-network-common_2.11\jars\spark-network-common_2.11-1.6.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\io.netty\netty-all\jars\netty-all-4.0.29.Final.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.spark\spark-network-shuffle_2.11\jars\spark-network-shuffle_2.11-1.6.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.fusesource.leveldbjni\leveldbjni-all\bundles\leveldbjni-all-1.8.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.fasterxml.jackson.core\jackson-databind\bundles\jackson-databind-2.4.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.fasterxml.jackson.core\jackson-annotations\bundles\jackson-annotations-2.4.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.fasterxml.jackson.core\jackson-core\bundles\jackson-core-2.4.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.spark\spark-unsafe_2.11\jars\spark-unsafe_2.11-1.6.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\net.java.dev.jets3t\jets3t\jars\jets3t-0.7.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.curator\curator-recipes\bundles\curator-recipes-2.4.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.curator\curator-framework\bundles\curator-framework-2.4.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.curator\curator-client\bundles\curator-client-2.4.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.zookeeper\zookeeper\jars\zookeeper-3.4.5.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\jline\jline\jars\jline-0.9.94.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.google.guava\guava\bundles\guava-14.0.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.eclipse.jetty.orbit\javax.servlet\orbits\javax.servlet-3.0.0.v201112011016.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.commons\commons-lang3\jars\commons-lang3-3.3.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.commons\commons-math3\jars\commons-math3-3.4.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.slf4j\jul-to-slf4j\jars\jul-to-slf4j-1.7.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.slf4j\jcl-over-slf4j\jars\jcl-over-slf4j-1.7.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.ning\compress-lzf\bundles\compress-lzf-1.0.3.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\net.jpountz.lz4\lz4\jars\lz4-1.3.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.roaringbitmap\RoaringBitmap\bundles\RoaringBitmap-0.5.11.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.typesafe.akka\akka-remote_2.11\jars\akka-remote_2.11-2.3.11.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.typesafe.akka\akka-actor_2.11\jars\akka-actor_2.11-2.3.11.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.typesafe\config\bundles\config-1.2.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\io.netty\netty\bundles\netty-3.8.0.Final.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.uncommons.maths\uncommons-maths\jars\uncommons-maths-1.2.2a.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.typesafe.akka\akka-slf4j_2.11\jars\akka-slf4j_2.11-2.3.11.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.json4s\json4s-jackson_2.11\jars\json4s-jackson_2.11-3.2.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.json4s\json4s-core_2.11\jars\json4s-core_2.11-3.2.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.json4s\json4s-ast_2.11\jars\json4s-ast_2.11-3.2.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.thoughtworks.paranamer\paranamer\jars\paranamer-2.6.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.scala-lang\scalap\jars\scalap-2.11.8.jar"/>
  <classpathentry kind="con" path="org.scala-ide.sdt.launching.SCALA_COMPILER_CONTAINER"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.scala-lang.modules\scala-xml_2.11\bundles\scala-xml_2.11-1.0.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.scala-lang.modules\scala-parser-combinators_2.11\bundles\scala-parser-combinators_2.11-1.0.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.sun.jersey\jersey-core\bundles\jersey-core-1.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.mesos\mesos\jars\mesos-0.21.1-shaded-protobuf.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.clearspring.analytics\stream\jars\stream-2.7.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\io.dropwizard.metrics\metrics-core\bundles\metrics-core-3.1.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\io.dropwizard.metrics\metrics-jvm\bundles\metrics-jvm-3.1.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\io.dropwizard.metrics\metrics-json\bundles\metrics-json-3.1.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\io.dropwizard.metrics\metrics-graphite\bundles\metrics-graphite-3.1.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\com.fasterxml.jackson.module\jackson-module-scala_2.11\bundles\jackson-module-scala_2.11-2.4.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.apache.ivy\ivy\jars\ivy-2.4.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\oro\oro\jars\oro-2.0.8.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.tachyonproject\tachyon-client\jars\tachyon-client-0.8.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\commons-io\commons-io\jars\commons-io-2.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.tachyonproject\tachyon-underfs-hdfs\jars\tachyon-underfs-hdfs-0.8.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.tachyonproject\tachyon-underfs-s3\jars\tachyon-underfs-s3-0.8.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\org.tachyonproject\tachyon-underfs-local\jars\tachyon-underfs-local-0.8.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\net.razorvine\pyrolite\jars\pyrolite-4.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\parul\.ivy2\cache\net.sf.py4j\py4j\jars\py4j-0.9.jar"/>
  <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
  <classpathentry kind="output" path="bin"/>
</classpath>
0 Likes

#4

#spark program executed in spark-shell

scala> sc.parallelize(List(5,4,6,8,9)).collect.foreach(println)

16/12/16 15:38:53 INFO spark.SparkContext: Starting job: collect at <console>:22
16/12/16 15:38:53 INFO scheduler.DAGScheduler: Got job 0 (collect at <console>:22) with 1 output partitions
16/12/16 15:38:53 INFO scheduler.DAGScheduler: Final stage: ResultStage 0(collect at <console>:22)
16/12/16 15:38:53 INFO scheduler.DAGScheduler: Parents of final stage: List()
16/12/16 15:38:53 INFO scheduler.DAGScheduler: Missing parents: List()
16/12/16 15:38:53 INFO scheduler.DAGScheduler: Submitting ResultStage 0 (ParallelCollectionRDD[0] at parallelize at <console>:22), which has no missing parents
16/12/16 15:38:53 INFO storage.MemoryStore: ensureFreeSpace(1272) called with curMem=0, maxMem=560497950
16/12/16 15:38:53 INFO storage.MemoryStore: Block broadcast_0 stored as values in memory (estimated size 1272.0 B, free 534.5 MB)
16/12/16 15:38:53 INFO storage.MemoryStore: ensureFreeSpace(843) called with curMem=1272, maxMem=560497950
16/12/16 15:38:53 INFO storage.MemoryStore: Block broadcast_0_piece0 stored as bytes in memory (estimated size 843.0 B, free 534.5 MB)
16/12/16 15:38:53 INFO storage.BlockManagerInfo: Added broadcast_0_piece0 in memory on localhost:35249 (size: 843.0 B, free: 534.5 MB)
16/12/16 15:38:53 INFO spark.SparkContext: Created broadcast 0 from broadcast at DAGScheduler.scala:861
16/12/16 15:38:53 INFO scheduler.DAGScheduler: Submitting 1 missing tasks from ResultStage 0 (ParallelCollectionRDD[0] at parallelize at <console>:22)
16/12/16 15:38:53 INFO scheduler.TaskSchedulerImpl: Adding task set 0.0 with 1 tasks
16/12/16 15:38:53 INFO scheduler.TaskSetManager: Starting task 0.0 in stage 0.0 (TID 0, localhost, partition 0,PROCESS_LOCAL, 2045 bytes)
16/12/16 15:38:53 INFO executor.Executor: Running task 0.0 in stage 0.0 (TID 0)
16/12/16 15:38:53 INFO executor.Executor: Finished task 0.0 in stage 0.0 (TID 0). 918 bytes result sent to driver
16/12/16 15:38:53 INFO scheduler.DAGScheduler: ResultStage 0 (collect at <console>:22) finished in 0.085 s
16/12/16 15:38:53 INFO scheduler.TaskSetManager: Finished task 0.0 in stage 0.0 (TID 0) in 72 ms on localhost (1/1)
16/12/16 15:38:53 INFO scheduler.TaskSchedulerImpl: Removed TaskSet 0.0, whose tasks have all completed, from pool
16/12/16 15:38:53 INFO scheduler.DAGScheduler: Job 0 finished: collect at <console>:22, took 0.414255 s
5
4
6
8
9

#contents of build.sbt and .classpath

name := "Spark Logs Analyzer with Spark 2.0.1"

version := "1.0"

scalaVersion := "2.10.4"

libraryDependencies += "org.apache.spark" % "spark-core_2.10" % "2.0.1"


resolvers += "Akka Repository" at "http://repo.akka.io/releases/"

.classpath

<classpath>
  <classpathentry kind="src" path="src\main\scala"/>
  <classpathentry kind="con" path="org.scala-ide.sdt.launching.SCALA_CONTAINER"/>
  <classpathentry sourcepath="C:\Users\farhan.misarwala\.ivy2\cache\mysql\mysql-connector-java\srcs\mysql-connector-java-5.1.24-sources.jar" kind="lib" path="C:\Users\farhan.misarwala\.ivy2\cache\mysql\mysql-connector-java\jars\mysql-connector-java-5.1.24.jar"/>
  <classpathentry sourcepath="C:\Users\farhan.misarwala\.ivy2\cache\org.apache.spark\spark-core_2.11\srcs\spark-core_2.11-1.6.2-sources.jar" kind="lib" path="C:\Users\farhan.misarwala\.ivy2\cache\org.apache.spark\spark-core_2.11\jars\spark-core_2.11-1.6.2.jar">
0 Likes

#5

#spark program executed in spark-shell

scala> val i = List(1, 2, 3, 4)
i: List[Int] = List(1, 2, 3, 4)

scala> sc.parallelize(i).collect().foreach(println)
1
2
3
4

#contents of build.sbt

name := "ScalaJdbcConnectSelect"
version := "1.0"
scalaVersion := "2.11.8"
libraryDependencies ++= Seq(“mysql” % “mysql-connector-java” % “5.1.24”,
“org.apache.spark” % “spark-core_2.11” % “1.6.2”
)

#contents of .classpath

<classpath>
  <classpathentry kind="src" path="src\main\scala"/>
  <classpathentry kind="src" path="src\main\resources"/>
  <classpathentry kind="con" path="org.scala-ide.sdt.launching.SCALA_CONTAINER"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\mysql\mysql-connector-java\jars\mysql-connector-java-5.1.24.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.spark\spark-core_2.11\jars\spark-core_2.11-1.6.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.avro\avro-mapred\jars\avro-mapred-1.7.7-hadoop2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.avro\avro-ipc\jars\avro-ipc-1.7.7-tests.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.avro\avro-ipc\jars\avro-ipc-1.7.7.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.avro\avro\jars\avro-1.7.7.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.codehaus.jackson\jackson-core-asl\jars\jackson-core-asl-1.9.13.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.codehaus.jackson\jackson-mapper-asl\jars\jackson-mapper-asl-1.9.13.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.xerial.snappy\snappy-java\bundles\snappy-java-1.1.2.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.commons\commons-compress\jars\commons-compress-1.4.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.tukaani\xz\jars\xz-1.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.slf4j\slf4j-api\jars\slf4j-api-1.7.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.twitter\chill_2.11\jars\chill_2.11-0.5.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.twitter\chill-java\jars\chill-java-0.5.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.esotericsoftware.kryo\kryo\bundles\kryo-2.21.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.esotericsoftware.reflectasm\reflectasm\jars\reflectasm-1.07-shaded.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.esotericsoftware.minlog\minlog\jars\minlog-1.2.jar"/>
  <classpathentry kind="lib" path="D:\typesafe-activator-1.3.12\activator-dist-1.3.12\repository\org.objenesis\objenesis\1.2\jars\objenesis.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.xbean\xbean-asm5-shaded\bundles\xbean-asm5-shaded-4.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-client\jars\hadoop-client-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-common\jars\hadoop-common-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-annotations\jars\hadoop-annotations-2.2.0.jar"/>
  <classpathentry kind="lib" path="D:\typesafe-activator-1.3.12\activator-dist-1.3.12\repository\com.google.code.findbugs\jsr305\1.3.9\jars\jsr305.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\commons-cli\commons-cli\jars\commons-cli-1.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.commons\commons-math\jars\commons-math-2.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\xmlenc\xmlenc\jars\xmlenc-0.52.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\commons-httpclient\commons-httpclient\jars\commons-httpclient-3.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\commons-codec\commons-codec\jars\commons-codec-1.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\commons-net\commons-net\jars\commons-net-2.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\log4j\log4j\bundles\log4j-1.2.17.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\commons-lang\commons-lang\jars\commons-lang-2.5.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\commons-configuration\commons-configuration\jars\commons-configuration-1.6.jar"/>
  <classpathentry kind="lib" path="D:\typesafe-activator-1.3.12\activator-dist-1.3.12\repository\commons-collections\commons-collections\3.2.1\jars\commons-collections.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\commons-digester\commons-digester\jars\commons-digester-1.8.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\commons-beanutils\commons-beanutils\jars\commons-beanutils-1.7.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\commons-beanutils\commons-beanutils-core\jars\commons-beanutils-core-1.8.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.google.protobuf\protobuf-java\bundles\protobuf-java-2.5.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-auth\jars\hadoop-auth-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-hdfs\jars\hadoop-hdfs-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.mortbay.jetty\jetty-util\jars\jetty-util-6.1.26.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-mapreduce-client-app\jars\hadoop-mapreduce-client-app-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-mapreduce-client-common\jars\hadoop-mapreduce-client-common-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-yarn-common\jars\hadoop-yarn-common-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-yarn-api\jars\hadoop-yarn-api-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.slf4j\slf4j-log4j12\jars\slf4j-log4j12-1.7.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.google.inject\guice\jars\guice-3.0.jar"/>
  <classpathentry kind="lib" path="D:\typesafe-activator-1.3.12\activator-dist-1.3.12\repository\javax.inject\javax.inject\1\jars\javax.inject.jar"/>
  <classpathentry kind="lib" path="D:\typesafe-activator-1.3.12\activator-dist-1.3.12\repository\aopalliance\aopalliance\1.0\jars\aopalliance.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.sonatype.sisu.inject\cglib\jars\cglib-2.2.1-v20090111.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.sun.jersey.jersey-test-framework\jersey-test-framework-grizzly2\jars\jersey-test-framework-grizzly2-1.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.sun.jersey\jersey-server\bundles\jersey-server-1.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\asm\asm\jars\asm-3.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.sun.jersey\jersey-json\bundles\jersey-json-1.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.codehaus.jettison\jettison\bundles\jettison-1.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\stax\stax-api\jars\stax-api-1.0.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.sun.xml.bind\jaxb-impl\jars\jaxb-impl-2.2.3-1.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\javax.xml.bind\jaxb-api\jars\jaxb-api-2.2.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\javax.activation\activation\jars\activation-1.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.codehaus.jackson\jackson-jaxrs\jars\jackson-jaxrs-1.8.3.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.codehaus.jackson\jackson-xc\jars\jackson-xc-1.8.3.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.sun.jersey.contribs\jersey-guice\jars\jersey-guice-1.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-yarn-client\jars\hadoop-yarn-client-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-mapreduce-client-core\jars\hadoop-mapreduce-client-core-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-yarn-server-common\jars\hadoop-yarn-server-common-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-mapreduce-client-shuffle\jars\hadoop-mapreduce-client-shuffle-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.hadoop\hadoop-mapreduce-client-jobclient\jars\hadoop-mapreduce-client-jobclient-2.2.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.spark\spark-launcher_2.11\jars\spark-launcher_2.11-1.6.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.spark-project.spark\unused\jars\unused-1.0.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.spark\spark-network-common_2.11\jars\spark-network-common_2.11-1.6.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\io.netty\netty-all\jars\netty-all-4.0.29.Final.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.spark\spark-network-shuffle_2.11\jars\spark-network-shuffle_2.11-1.6.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.fusesource.leveldbjni\leveldbjni-all\bundles\leveldbjni-all-1.8.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.fasterxml.jackson.core\jackson-databind\bundles\jackson-databind-2.4.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.fasterxml.jackson.core\jackson-annotations\bundles\jackson-annotations-2.4.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.fasterxml.jackson.core\jackson-core\bundles\jackson-core-2.4.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.spark\spark-unsafe_2.11\jars\spark-unsafe_2.11-1.6.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\net.java.dev.jets3t\jets3t\jars\jets3t-0.7.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.curator\curator-recipes\bundles\curator-recipes-2.4.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.curator\curator-framework\bundles\curator-framework-2.4.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.curator\curator-client\bundles\curator-client-2.4.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.zookeeper\zookeeper\jars\zookeeper-3.4.5.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\jline\jline\jars\jline-0.9.94.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.google.guava\guava\bundles\guava-14.0.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.eclipse.jetty.orbit\javax.servlet\orbits\javax.servlet-3.0.0.v201112011016.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.commons\commons-lang3\jars\commons-lang3-3.3.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.commons\commons-math3\jars\commons-math3-3.4.1.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.slf4j\jul-to-slf4j\jars\jul-to-slf4j-1.7.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.slf4j\jcl-over-slf4j\jars\jcl-over-slf4j-1.7.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.ning\compress-lzf\bundles\compress-lzf-1.0.3.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\net.jpountz.lz4\lz4\jars\lz4-1.3.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.roaringbitmap\RoaringBitmap\bundles\RoaringBitmap-0.5.11.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.typesafe.akka\akka-remote_2.11\jars\akka-remote_2.11-2.3.11.jar"/>
  <classpathentry kind="lib" path="D:\typesafe-activator-1.3.12\activator-dist-1.3.12\repository\com.typesafe.akka\akka-actor_2.11\2.3.11\jars\akka-actor_2.11.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.typesafe\config\bundles\config-1.2.1.jar"/>
  <classpathentry kind="lib" path="D:\typesafe-activator-1.3.12\activator-dist-1.3.12\repository\io.netty\netty\3.8.0.Final\bundles\netty.jar"/>
  <classpathentry kind="lib" path="D:\typesafe-activator-1.3.12\activator-dist-1.3.12\repository\org.uncommons.maths\uncommons-maths\1.2.2a\jars\uncommons-maths.jar"/>
  <classpathentry kind="lib" path="D:\typesafe-activator-1.3.12\activator-dist-1.3.12\repository\com.typesafe.akka\akka-slf4j_2.11\2.3.11\jars\akka-slf4j_2.11.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.json4s\json4s-jackson_2.11\jars\json4s-jackson_2.11-3.2.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.json4s\json4s-core_2.11\jars\json4s-core_2.11-3.2.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.json4s\json4s-ast_2.11\jars\json4s-ast_2.11-3.2.10.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.thoughtworks.paranamer\paranamer\jars\paranamer-2.6.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.scala-lang\scalap\jars\scalap-2.11.8.jar"/>
  <classpathentry kind="con" path="org.scala-ide.sdt.launching.SCALA_COMPILER_CONTAINER"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.scala-lang.modules\scala-xml_2.11\bundles\scala-xml_2.11-1.0.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.scala-lang.modules\scala-parser-combinators_2.11\bundles\scala-parser-combinators_2.11-1.0.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.sun.jersey\jersey-core\bundles\jersey-core-1.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.mesos\mesos\jars\mesos-0.21.1-shaded-protobuf.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.clearspring.analytics\stream\jars\stream-2.7.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\io.dropwizard.metrics\metrics-core\bundles\metrics-core-3.1.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\io.dropwizard.metrics\metrics-jvm\bundles\metrics-jvm-3.1.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\io.dropwizard.metrics\metrics-json\bundles\metrics-json-3.1.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\io.dropwizard.metrics\metrics-graphite\bundles\metrics-graphite-3.1.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\com.fasterxml.jackson.module\jackson-module-scala_2.11\bundles\jackson-module-scala_2.11-2.4.4.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.apache.ivy\ivy\jars\ivy-2.4.0.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\oro\oro\jars\oro-2.0.8.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.tachyonproject\tachyon-client\jars\tachyon-client-0.8.2.jar"/>
  <classpathentry kind="lib" path="D:\typesafe-activator-1.3.12\activator-dist-1.3.12\repository\commons-io\commons-io\2.4\jars\commons-io.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.tachyonproject\tachyon-underfs-hdfs\jars\tachyon-underfs-hdfs-0.8.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.tachyonproject\tachyon-underfs-s3\jars\tachyon-underfs-s3-0.8.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\org.tachyonproject\tachyon-underfs-local\jars\tachyon-underfs-local-0.8.2.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\net.razorvine\pyrolite\jars\pyrolite-4.9.jar"/>
  <classpathentry kind="lib" path="C:\Users\snehasish.dutta\.ivy2\cache\net.sf.py4j\py4j\jars\py4j-0.9.jar"/>
  <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
  <classpathentry kind="output" path="bin"/>
</classpath>
0 Likes

#6

scala> val i = List(1, 2, 3, 4)
i: List[Int] = List(1, 2, 3, 4)

scala> sc.parallelize(i).collect().foreach(println)
1
2
3
4
name := “hello”

version := “1.0”

scalaVersion := “2.10.2”

libraryDependencies += “org.scala-lang.modules” %% “scala-swing” % "1.0.1"
libraryDependencies += “org.apache.spark” % “spark-core_2.11” % “1.6.2”

0 Likes