Testsuite: org.apache.tomcat.websocket.server.TestClose Tests run: 10, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.708 sec ------------- Standard Error ----------------- 25-Nov-2024 12:47:25.623 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testTcpCloseInOnMessage] 25-Nov-2024 12:47:26.455 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-1"] 25-Nov-2024 12:47:26.500 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 25-Nov-2024 12:47:26.500 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.34-dev] 25-Nov-2024 12:47:26.720 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-1-40073"] 25-Nov-2024 12:47:26.823 INFO [http-nio-127.0.0.1-auto-1-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 25-Nov-2024 12:47:26.825 INFO [http-nio-127.0.0.1-auto-1-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage Message received: Test 25-Nov-2024 12:47:26.867 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:1293) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1181) 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:1741) 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) 25-Nov-2024 12:47:26.875 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] 25-Nov-2024 12:47:26.875 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-1-40073"] 25-Nov-2024 12:47:26.876 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 25-Nov-2024 12:47:26.889 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-1-40073"] 25-Nov-2024 12:47:26.904 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-1-40073"] 25-Nov-2024 12:47:26.910 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testWsCloseThenTcpCloseWhenOnMessageSends] 25-Nov-2024 12:47:26.912 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-2"] 25-Nov-2024 12:47:26.913 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 25-Nov-2024 12:47:26.913 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.34-dev] 25-Nov-2024 12:47:26.918 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-2-46073"] 25-Nov-2024 12:47:26.931 INFO [http-nio-127.0.0.1-auto-2-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 25-Nov-2024 12:47:26.932 INFO [http-nio-127.0.0.1-auto-2-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage Message received: Test 25-Nov-2024 12:47:27.441 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:1741) 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:1632) 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 25-Nov-2024 12:47:27.442 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] 25-Nov-2024 12:47:27.442 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:1251) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1181) 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:1741) 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) 25-Nov-2024 12:47:27.442 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-2-46073"] 25-Nov-2024 12:47:27.443 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 25-Nov-2024 12:47:27.445 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-2-46073"] 25-Nov-2024 12:47:27.447 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-2-46073"] 25-Nov-2024 12:47:27.449 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testTcpCloseWhenOnMessageSends] 25-Nov-2024 12:47:27.450 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-3"] 25-Nov-2024 12:47:27.451 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 25-Nov-2024 12:47:27.451 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.34-dev] 25-Nov-2024 12:47:27.456 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-3-44347"] 25-Nov-2024 12:47:27.460 INFO [http-nio-127.0.0.1-auto-3-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 25-Nov-2024 12:47:27.461 INFO [http-nio-127.0.0.1-auto-3-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage Message received: Test 25-Nov-2024 12:47:27.968 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:1741) 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:1632) 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 25-Nov-2024 12:47:27.969 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] 25-Nov-2024 12:47:27.969 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:1251) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1181) 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:1741) 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) 25-Nov-2024 12:47:27.969 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-3-44347"] 25-Nov-2024 12:47:27.970 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 25-Nov-2024 12:47:27.972 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-3-44347"] 25-Nov-2024 12:47:27.974 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-3-44347"] 25-Nov-2024 12:47:27.976 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testWsCloseThenTcpClose] 25-Nov-2024 12:47:27.978 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-4"] 25-Nov-2024 12:47:27.978 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 25-Nov-2024 12:47:27.978 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.34-dev] 25-Nov-2024 12:47:27.983 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-4-45235"] 25-Nov-2024 12:47:27.988 INFO [http-nio-127.0.0.1-auto-4-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 25-Nov-2024 12:47:27.989 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] 25-Nov-2024 12:47:27.989 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-4-45235"] 25-Nov-2024 12:47:27.990 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 25-Nov-2024 12:47:27.992 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-4-45235"] 25-Nov-2024 12:47:27.997 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-4-45235"] 25-Nov-2024 12:47:27.999 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testWsCloseThenTcpReset] 25-Nov-2024 12:47:28.000 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-5"] 25-Nov-2024 12:47:28.001 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 25-Nov-2024 12:47:28.001 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.34-dev] 25-Nov-2024 12:47:28.005 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-5-40837"] 25-Nov-2024 12:47:28.015 INFO [http-nio-127.0.0.1-auto-5-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 25-Nov-2024 12:47:28.016 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:1741) 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:1632) 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 25-Nov-2024 12:47:28.017 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] 25-Nov-2024 12:47:28.017 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-5-40837"] 25-Nov-2024 12:47:28.017 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 25-Nov-2024 12:47:28.020 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: app//org.apache.tomcat.util.collections.ManagedConcurrentWeakHashMap$Key.(ManagedConcurrentWeakHashMap.java:70) app//org.apache.tomcat.util.collections.ManagedConcurrentWeakHashMap.createLookupKey(ManagedConcurrentWeakHashMap.java:123) app//org.apache.tomcat.util.collections.ManagedConcurrentWeakHashMap.get(ManagedConcurrentWeakHashMap.java:157) app//org.apache.catalina.core.DefaultInstanceManager.preDestroy(DefaultInstanceManager.java:246) app//org.apache.catalina.core.DefaultInstanceManager.preDestroy(DefaultInstanceManager.java:241) app//org.apache.catalina.core.DefaultInstanceManager.preDestroy(DefaultInstanceManager.java:241) app//org.apache.catalina.core.DefaultInstanceManager.destroyInstance(DefaultInstanceManager.java:187) app//org.apache.tomcat.websocket.WsSession.fireEndpointOnClose(WsSession.java:740) 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:1741) 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) 25-Nov-2024 12:47:28.021 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-5-40837"] 25-Nov-2024 12:47:28.025 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-5-40837"] 25-Nov-2024 12:47:28.026 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testWsCloseThenTcpResetWhenOnMessageSends] 25-Nov-2024 12:47:28.028 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-6"] 25-Nov-2024 12:47:28.028 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 25-Nov-2024 12:47:28.028 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.34-dev] 25-Nov-2024 12:47:28.032 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-6-34249"] 25-Nov-2024 12:47:28.036 INFO [http-nio-127.0.0.1-auto-6-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 25-Nov-2024 12:47:28.036 INFO [http-nio-127.0.0.1-auto-6-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage Message received: Test 25-Nov-2024 12:47:28.037 INFO [http-nio-127.0.0.1-auto-6-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:1741) 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:1632) 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 25-Nov-2024 12:47:28.038 INFO [http-nio-127.0.0.1-auto-6-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onClose onClose: CloseReason: code [1006], reason [Connection reset by peer] 25-Nov-2024 12:47:28.038 INFO [http-nio-127.0.0.1-auto-6-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:1251) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1181) 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:1741) 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) 25-Nov-2024 12:47:28.039 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-6-34249"] 25-Nov-2024 12:47:28.039 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 25-Nov-2024 12:47:28.041 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-6-34249"] 25-Nov-2024 12:47:28.043 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-6-34249"] 25-Nov-2024 12:47:28.044 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testTcpResetWhenOnMessageSends] 25-Nov-2024 12:47:28.046 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-7"] 25-Nov-2024 12:47:28.046 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 25-Nov-2024 12:47:28.046 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.34-dev] 25-Nov-2024 12:47:28.050 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-7-45073"] 25-Nov-2024 12:47:28.055 INFO [http-nio-127.0.0.1-auto-7-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 25-Nov-2024 12:47:28.056 INFO [http-nio-127.0.0.1-auto-7-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage Message received: Test 25-Nov-2024 12:47:28.056 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:1741) 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:1632) 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 25-Nov-2024 12:47:28.057 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] 25-Nov-2024 12:47:28.057 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:1251) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1181) 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:1741) 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) 25-Nov-2024 12:47:28.058 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-7-45073"] 25-Nov-2024 12:47:28.058 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 25-Nov-2024 12:47:28.060 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-7-45073"] 25-Nov-2024 12:47:28.063 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-7-45073"] 25-Nov-2024 12:47:28.064 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testTcpResetInOnMessage] 25-Nov-2024 12:47:28.066 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-8"] 25-Nov-2024 12:47:28.066 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 25-Nov-2024 12:47:28.066 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.34-dev] 25-Nov-2024 12:47:28.070 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-8-44389"] 25-Nov-2024 12:47:28.075 INFO [http-nio-127.0.0.1-auto-8-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 25-Nov-2024 12:47:28.075 INFO [http-nio-127.0.0.1-auto-8-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onMessage Message received: Test 25-Nov-2024 12:47:28.079 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:1291) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1181) 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:1741) 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) 25-Nov-2024 12:47:28.080 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] 25-Nov-2024 12:47:28.081 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-8-44389"] 25-Nov-2024 12:47:28.081 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 25-Nov-2024 12:47:28.083 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-8-44389"] 25-Nov-2024 12:47:28.084 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-8-44389"] 25-Nov-2024 12:47:28.086 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testTcpClose] 25-Nov-2024 12:47:28.088 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-9"] 25-Nov-2024 12:47:28.088 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 25-Nov-2024 12:47:28.088 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.34-dev] 25-Nov-2024 12:47:28.091 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-9-39515"] 25-Nov-2024 12:47:28.096 INFO [http-nio-127.0.0.1-auto-9-exec-2] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 25-Nov-2024 12:47:28.097 INFO [http-nio-127.0.0.1-auto-9-exec-2] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onError onError java.io.EOFException at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1293) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1181) 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:1741) 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) 25-Nov-2024 12:47:28.097 INFO [http-nio-127.0.0.1-auto-9-exec-2] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onClose onClose: CloseReason: code [1006], reason [null] 25-Nov-2024 12:47:28.097 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-9-39515"] 25-Nov-2024 12:47:28.098 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 25-Nov-2024 12:47:28.100 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-9-39515"] 25-Nov-2024 12:47:28.104 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-9-39515"] 25-Nov-2024 12:47:28.105 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testTcpReset] 25-Nov-2024 12:47:28.107 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-10"] 25-Nov-2024 12:47:28.107 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat] 25-Nov-2024 12:47:28.108 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/10.1.34-dev] 25-Nov-2024 12:47:28.111 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-10-44993"] 25-Nov-2024 12:47:28.120 INFO [http-nio-127.0.0.1-auto-10-exec-1] org.apache.tomcat.websocket.server.TestClose$TestEndpoint.onOpen Session opened 25-Nov-2024 12:47:28.120 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:1291) at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1181) 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:1741) 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) 25-Nov-2024 12:47:28.121 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] 25-Nov-2024 12:47:28.121 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-10-44993"] 25-Nov-2024 12:47:28.122 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat] 25-Nov-2024 12:47:28.123 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-10-44993"] 25-Nov-2024 12:47:28.124 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-10-44993"] ------------- ---------------- --------------- Testcase: testTcpCloseInOnMessage took 1.433 sec Testcase: testWsCloseThenTcpCloseWhenOnMessageSends took 0.538 sec Testcase: testTcpCloseWhenOnMessageSends took 0.526 sec Testcase: testWsCloseThenTcpClose took 0.022 sec Testcase: testWsCloseThenTcpReset took 0.028 sec Testcase: testWsCloseThenTcpResetWhenOnMessageSends took 0.018 sec Testcase: testTcpResetWhenOnMessageSends took 0.02 sec Testcase: testTcpResetInOnMessage took 0.021 sec Testcase: testTcpClose took 0.019 sec Testcase: testTcpReset took 0.021 sec