Testsuite: org.apache.tomcat.websocket.TestWsWebSocketContainerTimeoutClient
Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 11.236 sec
------------- Standard Error -----------------
04-Dec-2024 19:46:20.182 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testWriteTimeoutClientEndpoint]
04-Dec-2024 19:46:20.750 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-1"]
04-Dec-2024 19:46:20.775 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat]
04-Dec-2024 19:46:20.776 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/11.0.2-dev]
04-Dec-2024 19:46:20.884 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-1-33195"]
04-Dec-2024 19:46:26.129 WARNING [main] org.apache.tomcat.websocket.WsRemoteEndpointImplClient.doWrite Write to the remote endpoint failed. The timeout passed to this method was [-1] and the timeout used for the write was [5,000]
	java.util.concurrent.TimeoutException
		at java.base/sun.nio.ch.PendingFuture.get(PendingFuture.java:195)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplClient.doWrite(WsRemoteEndpointImplClient.java:70)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase$OutputBufferSendHandler.onResult(WsRemoteEndpointImplBase.java:959)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplClient.doWrite(WsRemoteEndpointImplClient.java:78)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase$OutputBufferSendHandler.write(WsRemoteEndpointImplBase.java:947)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase$OutputBufferSendHandler.onResult(WsRemoteEndpointImplBase.java:962)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplClient.doWrite(WsRemoteEndpointImplClient.java:78)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase$OutputBufferSendHandler.write(WsRemoteEndpointImplBase.java:905)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.writeMessagePart(WsRemoteEndpointImplBase.java:521)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.startMessage(WsRemoteEndpointImplBase.java:415)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendBytesByCompletion(WsRemoteEndpointImplBase.java:158)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendBytesByFuture(WsRemoteEndpointImplBase.java:144)
		at org.apache.tomcat.websocket.WsRemoteEndpointAsync.sendBinary(WsRemoteEndpointAsync.java:58)
		at org.apache.tomcat.websocket.TestWsWebSocketContainerTimeoutClient.doTestWriteTimeoutClient(TestWsWebSocketContainerTimeoutClient.java:92)
		at org.apache.tomcat.websocket.TestWsWebSocketContainerTimeoutClient.testWriteTimeoutClientEndpoint(TestWsWebSocketContainerTimeoutClient.java:54)
		at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
		at java.base/java.lang.reflect.Method.invoke(Method.java:580)
		at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:59)
		at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
		at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:56)
		at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
		at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
		at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
		at org.junit.rules.TestWatcher$1.evaluate(TestWatcher.java:61)
		at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
		at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
		at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
		at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)
		at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63)
		at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
		at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
		at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
		at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
		at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
		at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
		at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
		at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
		at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
		at junit.framework.JUnit4TestAdapter.run(JUnit4TestAdapter.java:50)
		at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run(JUnitTestRunner.java:535)
		at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.launch(JUnitTestRunner.java:1197)
		at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.main(JUnitTestRunner.java:1042)
04-Dec-2024 19:46:26.134 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-1-33195"]
04-Dec-2024 19:46:26.137 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat]
04-Dec-2024 19:46:26.149 SEVERE [http-nio-127.0.0.1-auto-1-exec-3] org.apache.tomcat.websocket.pojo.PojoEndpointBase.onError No error handling configured for [org.apache.tomcat.websocket.TestWsWebSocketContainer$BlockingPojo] and the following error occurred
	java.net.SocketException: Connection reset
		at java.base/sun.nio.ch.SocketChannelImpl.throwConnectionReset(SocketChannelImpl.java:403)
		at java.base/sun.nio.ch.SocketChannelImpl.implRead(SocketChannelImpl.java:435)
		at java.base/sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:493)
		at org.apache.tomcat.util.net.NioChannel.read(NioChannel.java:147)
		at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1296)
		at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1249)
		at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1193)
		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:1746)
		at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52)
		at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1148)
		at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
		at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63)
		at java.base/java.lang.Thread.run(Thread.java:1570)
04-Dec-2024 19:46:26.150 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-1-exec-3] but has failed to stop it. This is very likely to create a memory leak. Stack trace of thread:
 java.base/java.lang.invoke.MethodTypeForm.<init>(MethodTypeForm.java:166)
 java.base/java.lang.invoke.MethodTypeForm.findForm(MethodTypeForm.java:223)
 java.base/java.lang.invoke.MethodType.makeImpl(MethodType.java:416)
 java.base/java.lang.invoke.MethodType.methodType(MethodType.java:382)
 java.base/java.lang.invoke.MethodTypeForm.canonicalize(MethodTypeForm.java:253)
 java.base/java.lang.invoke.MethodTypeForm.findForm(MethodTypeForm.java:220)
 java.base/java.lang.invoke.MethodType.makeImpl(MethodType.java:416)
 java.base/java.lang.invoke.MethodType.insertParameterTypes(MethodType.java:508)
 java.base/java.lang.invoke.VarHandle$AccessDescriptor.<init>(VarHandle.java:2024)
 java.base/java.lang.invoke.MethodHandleNatives.varHandleOperationLinkerMethod(MethodHandleNatives.java:554)
 java.base/java.lang.invoke.MethodHandleNatives.linkMethodImpl(MethodHandleNatives.java:498)
 java.base/java.lang.invoke.MethodHandleNatives.linkMethod(MethodHandleNatives.java:486)
 java.base/java.nio.channels.spi.AbstractSelectionKey.cancel(AbstractSelectionKey.java:81)
 java.base/java.nio.channels.spi.AbstractSelectableChannel.implCloseChannel(AbstractSelectableChannel.java:271)
 java.base/java.nio.channels.spi.AbstractInterruptibleChannel.close(AbstractInterruptibleChannel.java:113)
 org.apache.tomcat.util.net.NioChannel.close(NioChannel.java:83)
 org.apache.tomcat.util.net.NioChannel.close(NioChannel.java:94)
 org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.doClose(NioEndpoint.java:1217)
 org.apache.tomcat.util.net.SocketWrapperBase.close(SocketWrapperBase.java:424)
 org.apache.tomcat.websocket.server.WsRemoteEndpointImplServer.doClose(WsRemoteEndpointImplServer.java:298)
 org.apache.tomcat.websocket.WsRemoteEndpointImplBase.close(WsRemoteEndpointImplBase.java:753)
 org.apache.tomcat.websocket.WsSession.closeConnection(WsSession.java:669)
 org.apache.tomcat.websocket.WsSession.onClose(WsSession.java:659)
 org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.close(WsHttpUpgradeHandler.java:256)
 org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.upgradeDispatch(WsHttpUpgradeHandler.java:158)
 org.apache.coyote.http11.upgrade.UpgradeProcessorInternal.dispatch(UpgradeProcessorInternal.java:60)
 org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:57)
 org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:905)
 org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1746)
 org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52)
 org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1148)
 org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
 org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63)
 java.base/java.lang.Thread.run(Thread.java:1570)
04-Dec-2024 19:46:26.155 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-1-33195"]
04-Dec-2024 19:46:26.159 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-1-33195"]
04-Dec-2024 19:46:26.164 INFO [main] org.apache.catalina.startup.LoggingBaseTest.setUp Starting test case [testWriteTimeoutClientContainer]
04-Dec-2024 19:46:26.165 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-127.0.0.1-auto-2"]
04-Dec-2024 19:46:26.166 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Tomcat]
04-Dec-2024 19:46:26.166 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet engine: [Apache Tomcat/11.0.2-dev]
04-Dec-2024 19:46:26.170 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-127.0.0.1-auto-2-44101"]
04-Dec-2024 19:46:31.278 WARNING [main] org.apache.tomcat.websocket.WsRemoteEndpointImplClient.doWrite Write to the remote endpoint failed. The timeout passed to this method was [-1] and the timeout used for the write was [5,000]
	java.util.concurrent.TimeoutException
		at java.base/sun.nio.ch.PendingFuture.get(PendingFuture.java:195)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplClient.doWrite(WsRemoteEndpointImplClient.java:70)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase$OutputBufferSendHandler.onResult(WsRemoteEndpointImplBase.java:959)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplClient.doWrite(WsRemoteEndpointImplClient.java:78)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase$OutputBufferSendHandler.write(WsRemoteEndpointImplBase.java:947)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase$OutputBufferSendHandler.onResult(WsRemoteEndpointImplBase.java:962)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplClient.doWrite(WsRemoteEndpointImplClient.java:78)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase$OutputBufferSendHandler.write(WsRemoteEndpointImplBase.java:905)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.writeMessagePart(WsRemoteEndpointImplBase.java:521)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.startMessage(WsRemoteEndpointImplBase.java:415)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendBytesByCompletion(WsRemoteEndpointImplBase.java:158)
		at org.apache.tomcat.websocket.WsRemoteEndpointImplBase.sendBytesByFuture(WsRemoteEndpointImplBase.java:144)
		at org.apache.tomcat.websocket.WsRemoteEndpointAsync.sendBinary(WsRemoteEndpointAsync.java:58)
		at org.apache.tomcat.websocket.TestWsWebSocketContainerTimeoutClient.doTestWriteTimeoutClient(TestWsWebSocketContainerTimeoutClient.java:92)
		at org.apache.tomcat.websocket.TestWsWebSocketContainerTimeoutClient.testWriteTimeoutClientContainer(TestWsWebSocketContainerTimeoutClient.java:48)
		at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
		at java.base/java.lang.reflect.Method.invoke(Method.java:580)
		at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:59)
		at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
		at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:56)
		at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
		at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
		at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
		at org.junit.rules.TestWatcher$1.evaluate(TestWatcher.java:61)
		at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
		at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
		at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
		at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)
		at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63)
		at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
		at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
		at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
		at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
		at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
		at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
		at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
		at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
		at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
		at junit.framework.JUnit4TestAdapter.run(JUnit4TestAdapter.java:50)
		at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run(JUnitTestRunner.java:535)
		at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.launch(JUnitTestRunner.java:1197)
		at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.main(JUnitTestRunner.java:1042)
04-Dec-2024 19:46:31.280 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-127.0.0.1-auto-2-44101"]
04-Dec-2024 19:46:31.281 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Tomcat]
04-Dec-2024 19:46:31.284 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-127.0.0.1-auto-2-44101"]
04-Dec-2024 19:46:31.287 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-127.0.0.1-auto-2-44101"]
------------- ---------------- ---------------

Testcase: testWriteTimeoutClientEndpoint took 6.063 sec
Testcase: testWriteTimeoutClientContainer took 5.125 sec