Spark Cassandra NoClassDefFoundError guava/cache/CacheLoader

天涯浪子 提交于 2019-12-11 07:35:49

问题


Running Cassandra 2.2.8, Win7, JDK8, Spark2, HAve thse in the CP: Cassandra core 3.12, spark-cassandra-2.11, Spark-cassandra-java-2.11, Spark2.11, spark-network-common_2.11, Guava-16.0.jar, sacala2.11.jar, etc Trying to run a basic example- compiles fine, but when when I try to run- at the first line itself get error: SparkConf conf = new SparkConf(); java.lang.NoClassDefFoundError: org/spark_project/guava/cache/CacheLoader

Missing spark-network-common is supposed to cause this error - but I do have it. Any conflicting jars? Thanks


回答1:


So the answer is: don't exactly know the answer but the problem was solved. Used the the pom and created a maven project in eclipse. it brought in several (dozen) jars and it finally worked. So likely some conflicting/missing jar - tried to look into it- hard to figure out.



来源:https://stackoverflow.com/questions/40983971/spark-cassandra-noclassdeffounderror-guava-cache-cacheloader

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!