使用空指针异常启动tomcat 8.5时出错

时间:2019-07-17 12:05:43

标签: java spring-mvc tomcat java-ee

启动tomcat时,我正在追随某些动物,有人可以帮我解决吗?或告诉我我得到这个的原因。

    val spark = SparkSession
        .builder()
        .appName("ESToMongoDataUpload")
        .config("es.nodes", Config.ES_NODES)
        .config("es.net.http.auth.user", Config.ES_NET_HTTP_AUTH_USER)
        .config("es.net.http.auth.pass", Config.ES_NET_HTTP_AUTH_PASS)
        .config("es.net.ssl", Config.ES_NET_SSL)
        .config("es.nodes.wan.only", Config.ES_NODES_WAN_ONLY)
        .config("es.read.field.as.array.include", esConfig)
        .config("es.read.metadata", true)
        .config("spark.es.mapping.date.rich", false)
        .getOrCreate()


    import spark.implicits._

    val df = spark.read
        .format("org.elasticsearch.spark.sql")
        .option("query", esQuery)
        .option("pushdown", "true")
        .option("scroll.size", 10000)
        .load(Config.ES_RESOURCE)
        .withColumn("_id", $"_metadata".getItem("_id"))
        .drop("_metadata")

我在本地使用tomcat 8.5。启动服务器时,有时会出现此错误。

java.lang.NullPointerException
    org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:493)
    org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81)
    org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:660)
    org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
    org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:798)
    org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
    org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:808)
    org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1498)
    org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
    java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    java.lang.Thread.run(Thread.java:748)

0 个答案:

没有答案