对象com.github.nscala_time.time.Imports not found错误?

时间:2016-02-16 16:20:37

标签: java scala apache-spark

我在代码中使用了包com.github.nscala_time.time.Imports,我使用spark运行代码。 这是我的stream.sh文件:

#!/bin/bash
JARS_HOME=$HOME/spark-job/lib
JARS=$JARS_HOME/job-server-api_2.10-0.6.0.jar,$JARS_HOME/httpmime-4.4.1.jar,$JARS_HOME/noggit-0.6.jar,$JARS_HOME/nscala-time_2.10-2.0.0.jar
export SPARK_IP=`ifconfig | grep eth0 -1 | grep -i inet | awk '{ print $2 }' | cut -d':' -f2`
APP_JAR=$JARS_HOME/spark-jobs-tests.jar
export SPARK_LOCAL_IP=$SPARK_IP
dse spark-submit --conf "spark.cassandra.input.consistency.level=LOCAL_QUORUM" \
 --total-executor-cores 2 \
 --jars=$JARS \
 --class    "my file classpath" $APP_JAR  "$1" --files $1

我在.sh中设置了$ JARS_HOME / nscala-time_2.10-2.0.0.jar,然后仍然出现以下错误:

  Exception in thread "main" scala.reflect.internal.MissingRequirementError: object com.github.nscala_time.time.Imports not found.
at scala.reflect.internal.MissingRequirementError$.signal(MissingRequirementError.scala:16)
at scala.reflect.internal.MissingRequirementError$.notFound(MissingRequirementError.scala:17)
at scala.reflect.internal.Mirrors$RootsBase.ensureModuleSymbol(Mirrors.scala:126)
at scala.reflect.internal.Mirrors$RootsBase.staticModule(Mirrors.scala:161)
at scala.reflect.internal.Mirrors$RootsBase.staticModule(Mirrors.scala:21)

如何解决这个问题?

0 个答案:

没有答案