zzhangwa
发贴: 3
积分: 0
|
于 2003-07-30 19:42
现在有三个版本的Tomcat 4.1.24或者(5.0) jakarta-tomcat-4.1.12-LE-jdk14(jbuilder8自带) jakarta-tomcat-4.0.6-LE-jdk14(jbuidler8自带)
现在,我做了一个最简单的Servlet,然后将这个Servlet作为了启动级的Servlet(应用服务器启动时,自动加载),然后,我在它的destroy方法中,加入了下面的语句 try{ Thread.sleep(5000); } catch(Exception ex){ ex.toString() }
但是在上面的三个不同版本的Tomcat中,当我使用这个servlet并关闭Tomcat的时候,4.1.24报出了下面的错误。而另外的两个版本没有错误。
2003-7-29 11:00:00 org.apache.tomcat.util.net.PoolTcpEndpoint closeServerSocket
严重: Caught exception trying to unlock accept.
java.net.ConnectException: Connection refused: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:305)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:171)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:158)
at java.net.Socket.connect(Socket.java:426)
at java.net.Socket.connect(Socket.java:376)
at java.net.Socket.<init>(Socket.java:291)
at java.net.Socket.<init>(Socket.java:119)
at org.apache.tomcat.util.net.PoolTcpEndpoint.closeServerSocket(PoolTcpEndpoint.java:326)
at org.apache.tomcat.util.net.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoint.java:397)
at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:529)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:619)
at java.lang.Thread.run(Thread.java:536)
2003-7-29 11:00:00 org.apache.tomcat.util.net.PoolTcpEndpoint closeServerSocket
严重: Caught exception trying to close socket.
java.lang.NullPointerException
at org.apache.tomcat.util.net.PoolTcpEndpoint.closeServerSocket(PoolTcpEndpoint.java:338)
at org.apache.tomcat.util.net.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoint.java:397)
at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:529)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:619)
at java.lang.Thread.run(Thread.java:536)
2003-7-29 11:00:00 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
警告: Reinitializing ServerSocket
|