3

使用 Tomcat 服务器 8.5.4 作为独立服务 (tomcat8w.exe),当我停止服务器时,我在“logs/tomcat8-stderr.YYYY-MM-DD.txt”中收到以下错误:

org.apache.coyote.AbstractProtocol$ConnectionHandler.process Error reading request, ignored
java.lang.NullPointerException
at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.getSslSupport(NioEndpoint.java:1349)
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:775)
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1425)
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
at org.apache.tomcat.util.net.AbstractEndpoint.processSocket(AbstractEndpoint.java:830)
at org.apache.tomcat.util.net.NioEndpoint$Poller.add(NioEndpoint.java:669)
at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.registerReadInterest(NioEndpoint.java:1264)
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1433)
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.lang.Thread.run(Thread.java:745)

我的连接器如下:

<Connector SSLEnabled="true" clientAuth="false" keyAlias="xxx" keystoreFile="F:\Programs\apache-tomcat-8.5.4\certificate\xxx.keystore" keystorePass="xxx" maxThreads="150" port="443" protocol="org.apache.coyote.http11.Http11NioProtocol" sslImplementationName="org.apache.tomcat.util.net.jsse.JSSEImplementation" scheme="https" secure="true" sslEnabledProtocols="all" sslProtocol="SSL"/>

您对这里可能出现的问题有任何解释吗?

4

1 回答 1

1

经过一番研究,我发现用 'org.apache.coyote.http11.Http11Nio2Protocol' 替换 'org.apache.coyote.http11.Http11NioProtocol' 是可行的。我解决了我的问题,但仍然欢迎对此发表任何评论/建议或解决方案。

于 2016-09-19T15:54:19.913 回答