Testsuite: org.apache.tomcat.websocket.server.TestClose Tests run: 10, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.145 sec ------------- Standard Error ----------------- 07-Jan-2025 12:40:27.876 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testTcpCloseInOnMessage] 07-Jan-2025 12:40:28.335 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-1"] 07-Jan-2025 12:40:28.358 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 07-Jan-2025 12:40:28.358 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.35-dev] 07-Jan-2025 12:40:28.471 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-1-34867"] 07-Jan-2025 12:40:28.587 INFO [http-nio-127.0.0.1-auto-1-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 07-Jan-2025 12:40:28.590 INFO [http-nio-127.0.0.1-auto-1-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage Message received: Test 07-Jan-2025 12:40:28.633 INFO [http-nio-127.0.0.1-auto-1-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.io.EOFException at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1295) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1183) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:74) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) 07-Jan-2025 12:40:28.639 INFO [http-nio-127.0.0.1-auto-1-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onClose onClose: CloseReason: code [1006], reason [null] 07-Jan-2025 12:40:28.639 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-1-34867"] 07-Jan-2025 12:40:28.641 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 07-Jan-2025 12:40:28.654 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-1-34867"] 07-Jan-2025 12:40:28.664 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-1-34867"] 07-Jan-2025 12:40:28.676 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testWsCloseThenTcpCloseWhenOnMessageSends] 07-Jan-2025 12:40:28.678 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-2"] 07-Jan-2025 12:40:28.678 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 07-Jan-2025 12:40:28.678 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.35-dev] 07-Jan-2025 12:40:28.683 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-2-40361"] 07-Jan-2025 12:40:28.697 INFO [http-nio-127.0.0.1-auto-2-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 07-Jan-2025 12:40:28.700 INFO [http-nio-127.0.0.1-auto-2-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage Message received: Test 07-Jan-2025 12:40:29.210 INFO [http-nio-127.0.0.1-auto-2-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.io.IOException: java.io.IOException: Broken pipe at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:326) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:266) at org.apache.tomcat.websocket.WsSession.sendCloseMessage(WsSession.java:792) at org.apache.tomcat.websocket.WsSession.doClose(WsSession.java:589) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:324) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:266) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:250) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendString(WsRemoteEndpointImplBase.java:192) at org.apache.tomcat.websocket.WsRemoteEndpointBasic.sendText(WsRemoteEndpointBasic.java:36) at org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage(TestClose.java:284) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:569) at org.apache.tomcat.websocket.pojo.PojoMessageHandlerWholeBase.onMessage(PojoMessageHandlerWholeBase.java:102) at org.apache.tomcat.websocket.WsFrameBase.sendMessageText(WsFrameBase.java:390) at org.apache.tomcat.websocket.server.WsFrameServer.sendMessageText(WsFrameServer.java:130) at org.apache.tomcat.websocket.WsFrameBase.processDataText(WsFrameBase.java:484) at org.apache.tomcat.websocket.WsFrameBase.processData(WsFrameBase.java:284) at org.apache.tomcat.websocket.WsFrameBase.processInputBuffer(WsFrameBase.java:130) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:85) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) Caused by: java.io.IOException: Broken pipe at java.base/sun.nio.ch.FileDispatcherImpl.writev0(Native Method) at java.base/sun.nio.ch.SocketDispatcher.writev(SocketDispatcher.java:66) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:217) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:153) at java.base/sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:563) at org.apache.tomcat.util.net.NioChannel.write(NioChannel.java:134) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper$NioOperationState.run(NioEndpoint.java:1634) at org.apache.tomcat.util.net.SocketWrapperBase$OperationState.start(SocketWrapperBase.java:1051) at org.apache.tomcat.util.net.SocketWrapperBase.vectoredOperation(SocketWrapperBase.java:1440) at org.apache.tomcat.util.net.SocketWrapperBase.write(SocketWrapperBase.java:1366) at org.apache.tomcat.util.net.SocketWrapperBase.write(SocketWrapperBase.java:1337) at org.apache.tomcat.websocket.server.WsRemoteEndpointImplServer.doWrite(WsRemoteEndpointImplServer.java:171) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.writeMessagePart(WsRemoteEndpointImplBase.java:521) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:313) ... 28 more 07-Jan-2025 12:40:29.211 INFO [http-nio-127.0.0.1-auto-2-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onClose onClose: CloseReason: code [1006], reason [Broken pipe] 07-Jan-2025 12:40:29.211 INFO [http-nio-127.0.0.1-auto-2-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.nio.channels.ClosedChannelException at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1253) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1183) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:74) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) 07-Jan-2025 12:40:29.211 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-2-40361"] 07-Jan-2025 12:40:29.212 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 07-Jan-2025 12:40:29.214 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-2-40361"] 07-Jan-2025 12:40:29.217 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-2-40361"] 07-Jan-2025 12:40:29.219 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testTcpCloseWhenOnMessageSends] 07-Jan-2025 12:40:29.220 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-3"] 07-Jan-2025 12:40:29.220 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 07-Jan-2025 12:40:29.220 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.35-dev] 07-Jan-2025 12:40:29.225 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-3-42925"] 07-Jan-2025 12:40:29.230 INFO [http-nio-127.0.0.1-auto-3-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 07-Jan-2025 12:40:29.230 INFO [http-nio-127.0.0.1-auto-3-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage Message received: Test 07-Jan-2025 12:40:29.737 INFO [http-nio-127.0.0.1-auto-3-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.io.IOException: java.io.IOException: Broken pipe at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:326) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:266) at org.apache.tomcat.websocket.WsSession.sendCloseMessage(WsSession.java:792) at org.apache.tomcat.websocket.WsSession.doClose(WsSession.java:589) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:324) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:266) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:250) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendString(WsRemoteEndpointImplBase.java:192) at org.apache.tomcat.websocket.WsRemoteEndpointBasic.sendText(WsRemoteEndpointBasic.java:36) at org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage(TestClose.java:284) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:569) at org.apache.tomcat.websocket.pojo.PojoMessageHandlerWholeBase.onMessage(PojoMessageHandlerWholeBase.java:102) at org.apache.tomcat.websocket.WsFrameBase.sendMessageText(WsFrameBase.java:390) at org.apache.tomcat.websocket.server.WsFrameServer.sendMessageText(WsFrameServer.java:130) at org.apache.tomcat.websocket.WsFrameBase.processDataText(WsFrameBase.java:484) at org.apache.tomcat.websocket.WsFrameBase.processData(WsFrameBase.java:284) at org.apache.tomcat.websocket.WsFrameBase.processInputBuffer(WsFrameBase.java:130) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:85) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) Caused by: java.io.IOException: Broken pipe at java.base/sun.nio.ch.FileDispatcherImpl.writev0(Native Method) at java.base/sun.nio.ch.SocketDispatcher.writev(SocketDispatcher.java:66) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:217) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:153) at java.base/sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:563) at org.apache.tomcat.util.net.NioChannel.write(NioChannel.java:134) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper$NioOperationState.run(NioEndpoint.java:1634) at org.apache.tomcat.util.net.SocketWrapperBase$OperationState.start(SocketWrapperBase.java:1051) at org.apache.tomcat.util.net.SocketWrapperBase.vectoredOperation(SocketWrapperBase.java:1440) at org.apache.tomcat.util.net.SocketWrapperBase.write(SocketWrapperBase.java:1366) at org.apache.tomcat.util.net.SocketWrapperBase.write(SocketWrapperBase.java:1337) at org.apache.tomcat.websocket.server.WsRemoteEndpointImplServer.doWrite(WsRemoteEndpointImplServer.java:171) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.writeMessagePart(WsRemoteEndpointImplBase.java:521) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:313) ... 28 more 07-Jan-2025 12:40:29.738 INFO [http-nio-127.0.0.1-auto-3-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onClose onClose: CloseReason: code [1006], reason [Broken pipe] 07-Jan-2025 12:40:29.738 INFO [http-nio-127.0.0.1-auto-3-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.nio.channels.ClosedChannelException at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1253) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1183) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:74) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) 07-Jan-2025 12:40:29.739 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-3-42925"] 07-Jan-2025 12:40:29.739 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 07-Jan-2025 12:40:29.742 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-3-42925"] 07-Jan-2025 12:40:29.744 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-3-42925"] 07-Jan-2025 12:40:29.745 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testWsCloseThenTcpClose] 07-Jan-2025 12:40:29.746 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-4"] 07-Jan-2025 12:40:29.747 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 07-Jan-2025 12:40:29.747 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.35-dev] 07-Jan-2025 12:40:29.751 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-4-46115"] 07-Jan-2025 12:40:29.758 INFO [http-nio-127.0.0.1-auto-4-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 07-Jan-2025 12:40:29.759 INFO [http-nio-127.0.0.1-auto-4-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onClose onClose: CloseReason: code [1001], reason [null] 07-Jan-2025 12:40:29.760 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-4-46115"] 07-Jan-2025 12:40:29.760 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 07-Jan-2025 12:40:29.763 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-4-46115"] 07-Jan-2025 12:40:29.765 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-4-46115"] 07-Jan-2025 12:40:29.767 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testWsCloseThenTcpReset] 07-Jan-2025 12:40:29.769 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-5"] 07-Jan-2025 12:40:29.769 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 07-Jan-2025 12:40:29.770 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.35-dev] 07-Jan-2025 12:40:29.774 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-5-35549"] 07-Jan-2025 12:40:29.779 INFO [http-nio-127.0.0.1-auto-5-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 07-Jan-2025 12:40:29.780 INFO [http-nio-127.0.0.1-auto-5-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.io.IOException: java.io.IOException: Connection reset by peer at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:326) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:266) at org.apache.tomcat.websocket.WsSession.sendCloseMessage(WsSession.java:792) at org.apache.tomcat.websocket.WsSession.onClose(WsSession.java:640) at org.apache.tomcat.websocket.WsFrameBase.processDataControl(WsFrameBase.java:347) at org.apache.tomcat.websocket.WsFrameBase.processData(WsFrameBase.java:279) at org.apache.tomcat.websocket.WsFrameBase.processInputBuffer(WsFrameBase.java:130) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:85) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) Caused by: java.io.IOException: Connection reset by peer at java.base/sun.nio.ch.FileDispatcherImpl.writev0(Native Method) at java.base/sun.nio.ch.SocketDispatcher.writev(SocketDispatcher.java:66) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:217) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:153) at java.base/sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:563) at org.apache.tomcat.util.net.NioChannel.write(NioChannel.java:134) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper$NioOperationState.run(NioEndpoint.java:1634) at org.apache.tomcat.util.net.SocketWrapperBase$OperationState.start(SocketWrapperBase.java:1051) at org.apache.tomcat.util.net.SocketWrapperBase.vectoredOperation(SocketWrapperBase.java:1440) at org.apache.tomcat.util.net.SocketWrapperBase.write(SocketWrapperBase.java:1366) at org.apache.tomcat.util.net.SocketWrapperBase.write(SocketWrapperBase.java:1337) at org.apache.tomcat.websocket.server.WsRemoteEndpointImplServer.doWrite(WsRemoteEndpointImplServer.java:171) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.writeMessagePart(WsRemoteEndpointImplBase.java:521) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:313) ... 19 more 07-Jan-2025 12:40:29.781 INFO [http-nio-127.0.0.1-auto-5-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onClose onClose: CloseReason: code [1001], reason [null] 07-Jan-2025 12:40:29.781 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-5-35549"] 07-Jan-2025 12:40:29.781 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 07-Jan-2025 12:40:29.784 WARNING [main] org.apache.catalina.loader.WebappClassLoaderBase.clearReferencesThreads The web application [ROOT] appears to have started a thread named [http-nio-127.0.0.1-auto-5-exec-1] but has failed to stop it. This is very likely to create a memory leak. Stack trace of thread: java.base@17.0.12/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) java.base@17.0.12/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) java.base@17.0.12/java.lang.reflect.Method.invoke(Method.java:569) app//org.apache.tomcat.websocket.pojo.PojoEndpointBase.onClose(PojoEndpointBase.java:101) app//org.apache.tomcat.websocket.WsSession.fireEndpointOnClose(WsSession.java:733) app//org.apache.tomcat.websocket.WsSession.onClose(WsSession.java:641) app//org.apache.tomcat.websocket.WsFrameBase.processDataControl(WsFrameBase.java:347) app//org.apache.tomcat.websocket.WsFrameBase.processData(WsFrameBase.java:279) app//org.apache.tomcat.websocket.WsFrameBase.processInputBuffer(WsFrameBase.java:130) app//org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:85) app//org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) app//org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) app//org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) app//org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) app//org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) app//org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) app//org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) app//org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) app//org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) app//org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) app//org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) java.base@17.0.12/java.lang.Thread.run(Thread.java:840) 07-Jan-2025 12:40:29.784 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-5-35549"] 07-Jan-2025 12:40:29.787 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-5-35549"] 07-Jan-2025 12:40:29.788 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testWsCloseThenTcpResetWhenOnMessageSends] 07-Jan-2025 12:40:29.790 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-6"] 07-Jan-2025 12:40:29.791 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 07-Jan-2025 12:40:29.791 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.35-dev] 07-Jan-2025 12:40:29.796 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-6-34189"] 07-Jan-2025 12:40:29.801 INFO [http-nio-127.0.0.1-auto-6-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 07-Jan-2025 12:40:29.802 INFO [http-nio-127.0.0.1-auto-6-exec-2] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage Message received: Test 07-Jan-2025 12:40:29.803 INFO [http-nio-127.0.0.1-auto-6-exec-2] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.io.IOException: java.io.IOException: Connection reset by peer at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:326) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:266) at org.apache.tomcat.websocket.WsSession.sendCloseMessage(WsSession.java:792) at org.apache.tomcat.websocket.WsSession.doClose(WsSession.java:589) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:324) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:266) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:250) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendString(WsRemoteEndpointImplBase.java:192) at org.apache.tomcat.websocket.WsRemoteEndpointBasic.sendText(WsRemoteEndpointBasic.java:36) at org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage(TestClose.java:284) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:569) at org.apache.tomcat.websocket.pojo.PojoMessageHandlerWholeBase.onMessage(PojoMessageHandlerWholeBase.java:102) at org.apache.tomcat.websocket.WsFrameBase.sendMessageText(WsFrameBase.java:390) at org.apache.tomcat.websocket.server.WsFrameServer.sendMessageText(WsFrameServer.java:130) at org.apache.tomcat.websocket.WsFrameBase.processDataText(WsFrameBase.java:484) at org.apache.tomcat.websocket.WsFrameBase.processData(WsFrameBase.java:284) at org.apache.tomcat.websocket.WsFrameBase.processInputBuffer(WsFrameBase.java:130) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:85) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) Caused by: java.io.IOException: Connection reset by peer at java.base/sun.nio.ch.FileDispatcherImpl.writev0(Native Method) at java.base/sun.nio.ch.SocketDispatcher.writev(SocketDispatcher.java:66) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:217) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:153) at java.base/sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:563) at org.apache.tomcat.util.net.NioChannel.write(NioChannel.java:134) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper$NioOperationState.run(NioEndpoint.java:1634) at org.apache.tomcat.util.net.SocketWrapperBase$OperationState.start(SocketWrapperBase.java:1051) at org.apache.tomcat.util.net.SocketWrapperBase.vectoredOperation(SocketWrapperBase.java:1440) at org.apache.tomcat.util.net.SocketWrapperBase.write(SocketWrapperBase.java:1366) at org.apache.tomcat.util.net.SocketWrapperBase.write(SocketWrapperBase.java:1337) at org.apache.tomcat.websocket.server.WsRemoteEndpointImplServer.doWrite(WsRemoteEndpointImplServer.java:171) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.writeMessagePart(WsRemoteEndpointImplBase.java:521) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:313) ... 28 more 07-Jan-2025 12:40:29.804 INFO [http-nio-127.0.0.1-auto-6-exec-2] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onClose onClose: CloseReason: code [1006], reason [Connection reset by peer] 07-Jan-2025 12:40:29.804 INFO [http-nio-127.0.0.1-auto-6-exec-2] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.nio.channels.ClosedChannelException at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1253) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1183) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:74) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) 07-Jan-2025 12:40:29.805 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-6-34189"] 07-Jan-2025 12:40:29.806 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 07-Jan-2025 12:40:29.808 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-6-34189"] 07-Jan-2025 12:40:29.810 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-6-34189"] 07-Jan-2025 12:40:29.812 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testTcpResetWhenOnMessageSends] 07-Jan-2025 12:40:29.813 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-7"] 07-Jan-2025 12:40:29.814 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 07-Jan-2025 12:40:29.814 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.35-dev] 07-Jan-2025 12:40:29.818 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-7-45129"] 07-Jan-2025 12:40:29.825 INFO [http-nio-127.0.0.1-auto-7-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 07-Jan-2025 12:40:29.825 INFO [http-nio-127.0.0.1-auto-7-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage Message received: Test 07-Jan-2025 12:40:29.826 INFO [http-nio-127.0.0.1-auto-7-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.io.IOException: java.io.IOException: Connection reset by peer at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:326) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:266) at org.apache.tomcat.websocket.WsSession.sendCloseMessage(WsSession.java:792) at org.apache.tomcat.websocket.WsSession.doClose(WsSession.java:589) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:324) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:266) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlock(WsRemoteEndpointImplBase.java:250) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendString(WsRemoteEndpointImplBase.java:192) at org.apache.tomcat.websocket.WsRemoteEndpointBasic.sendText(WsRemoteEndpointBasic.java:36) at org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage(TestClose.java:284) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:569) at org.apache.tomcat.websocket.pojo.PojoMessageHandlerWholeBase.onMessage(PojoMessageHandlerWholeBase.java:102) at org.apache.tomcat.websocket.WsFrameBase.sendMessageText(WsFrameBase.java:390) at org.apache.tomcat.websocket.server.WsFrameServer.sendMessageText(WsFrameServer.java:130) at org.apache.tomcat.websocket.WsFrameBase.processDataText(WsFrameBase.java:484) at org.apache.tomcat.websocket.WsFrameBase.processData(WsFrameBase.java:284) at org.apache.tomcat.websocket.WsFrameBase.processInputBuffer(WsFrameBase.java:130) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:85) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) Caused by: java.io.IOException: Connection reset by peer at java.base/sun.nio.ch.FileDispatcherImpl.writev0(Native Method) at java.base/sun.nio.ch.SocketDispatcher.writev(SocketDispatcher.java:66) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:217) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:153) at java.base/sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:563) at org.apache.tomcat.util.net.NioChannel.write(NioChannel.java:134) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper$NioOperationState.run(NioEndpoint.java:1634) at org.apache.tomcat.util.net.SocketWrapperBase$OperationState.start(SocketWrapperBase.java:1051) at org.apache.tomcat.util.net.SocketWrapperBase.vectoredOperation(SocketWrapperBase.java:1440) at org.apache.tomcat.util.net.SocketWrapperBase.write(SocketWrapperBase.java:1366) at org.apache.tomcat.util.net.SocketWrapperBase.write(SocketWrapperBase.java:1337) at org.apache.tomcat.websocket.server.WsRemoteEndpointImplServer.doWrite(WsRemoteEndpointImplServer.java:171) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.writeMessagePart(WsRemoteEndpointImplBase.java:521) at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendMessageBlockInternal(WsRemoteEndpointImplBase.java:313) ... 28 more 07-Jan-2025 12:40:29.827 INFO [http-nio-127.0.0.1-auto-7-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onClose onClose: CloseReason: code [1006], reason [Connection reset by peer] 07-Jan-2025 12:40:29.827 INFO [http-nio-127.0.0.1-auto-7-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.nio.channels.ClosedChannelException at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1253) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1183) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:74) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) 07-Jan-2025 12:40:29.827 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-7-45129"] 07-Jan-2025 12:40:29.828 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 07-Jan-2025 12:40:29.830 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-7-45129"] 07-Jan-2025 12:40:29.833 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-7-45129"] 07-Jan-2025 12:40:29.834 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testTcpResetInOnMessage] 07-Jan-2025 12:40:29.836 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-8"] 07-Jan-2025 12:40:29.836 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 07-Jan-2025 12:40:29.836 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.35-dev] 07-Jan-2025 12:40:29.841 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-8-44317"] 07-Jan-2025 12:40:29.848 INFO [http-nio-127.0.0.1-auto-8-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 07-Jan-2025 12:40:29.852 INFO [http-nio-127.0.0.1-auto-8-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage Message received: Test 07-Jan-2025 12:40:29.853 INFO [http-nio-127.0.0.1-auto-8-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.net.SocketException: Connection reset at java.base/sun.nio.ch.SocketChannelImpl.throwConnectionReset(SocketChannelImpl.java:394) at java.base/sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:426) at org.apache.tomcat.util.net.NioChannel.read(NioChannel.java:147) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1293) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1183) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:74) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) 07-Jan-2025 12:40:29.853 INFO [http-nio-127.0.0.1-auto-8-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onClose onClose: CloseReason: code [1006], reason [Connection reset] 07-Jan-2025 12:40:29.854 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-8-44317"] 07-Jan-2025 12:40:29.856 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 07-Jan-2025 12:40:29.858 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-8-44317"] 07-Jan-2025 12:40:29.860 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-8-44317"] 07-Jan-2025 12:40:29.861 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testTcpClose] 07-Jan-2025 12:40:29.863 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-9"] 07-Jan-2025 12:40:29.863 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 07-Jan-2025 12:40:29.863 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.35-dev] 07-Jan-2025 12:40:29.867 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-9-35601"] 07-Jan-2025 12:40:29.872 INFO [http-nio-127.0.0.1-auto-9-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 07-Jan-2025 12:40:29.873 INFO [http-nio-127.0.0.1-auto-9-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.io.EOFException at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1295) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1183) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:74) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) 07-Jan-2025 12:40:29.873 INFO [http-nio-127.0.0.1-auto-9-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onClose onClose: CloseReason: code [1006], reason [null] 07-Jan-2025 12:40:29.874 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-9-35601"] 07-Jan-2025 12:40:29.874 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 07-Jan-2025 12:40:29.876 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-9-35601"] 07-Jan-2025 12:40:29.878 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-9-35601"] 07-Jan-2025 12:40:29.879 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testTcpReset] 07-Jan-2025 12:40:29.880 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-10"] 07-Jan-2025 12:40:29.881 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 07-Jan-2025 12:40:29.881 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.35-dev] 07-Jan-2025 12:40:29.884 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-10-40753"] 07-Jan-2025 12:40:29.898 INFO [http-nio-127.0.0.1-auto-10-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 07-Jan-2025 12:40:29.898 INFO [http-nio-127.0.0.1-auto-10-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.net.SocketException: Connection reset at java.base/sun.nio.ch.SocketChannelImpl.throwConnectionReset(SocketChannelImpl.java:394) at java.base/sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:426) at org.apache.tomcat.util.net.NioChannel.read(NioChannel.java:147) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1293) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1183) at org.apache.tomcat.websocket.server.WsFrameServer.onDataAvailable(WsFrameServer.java:74) at org.apache.tomcat.websocket.server.WsFrameServer.doOnDataAvailable(WsFrameServer.java:184) at org.apache.tomcat.websocket.server.WsFrameServer.notifyDataAvailable(WsFrameServer.java:164) at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:152) at org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1743) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52) at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190) at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63) at java.base/java.lang.Thread.run(Thread.java:840) 07-Jan-2025 12:40:29.899 INFO [http-nio-127.0.0.1-auto-10-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onClose onClose: CloseReason: code [1006], reason [Connection reset] 07-Jan-2025 12:40:29.899 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-10-40753"] 07-Jan-2025 12:40:29.899 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 07-Jan-2025 12:40:29.901 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-10-40753"] 07-Jan-2025 12:40:29.907 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-10-40753"] ------------- ---------------- --------------- Testcase: testTcpCloseInOnMessage took 0.873 sec Testcase: testWsCloseThenTcpCloseWhenOnMessageSends took 0.542 sec Testcase: testTcpCloseWhenOnMessageSends took 0.527 sec Testcase: testWsCloseThenTcpClose took 0.021 sec Testcase: testWsCloseThenTcpReset took 0.022 sec Testcase: testWsCloseThenTcpResetWhenOnMessageSends took 0.023 sec Testcase: testTcpResetWhenOnMessageSends took 0.023 sec Testcase: testTcpResetInOnMessage took 0.027 sec Testcase: testTcpClose took 0.018 sec Testcase: testTcpReset took 0.029 sec