JDK-8254786 : java/net/httpclient/CancelRequestTest.java failing intermittently
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.net
  • Affected Version: 16
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • Submitted: 2020-10-14
  • Updated: 2022-12-10
  • Resolved: 2022-03-15
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 19
19 b14Fixed
Related Reports
Relates :  
Relates :  
Description
----------System.out:(668/57490)----------
Seed from RandomFactory = -6115751403128181362L
[TestNG] Running:
  java/net/httpclient/CancelRequestTest.java
....
test CancelRequestTest.testGetSendAsync("http://localhost:45759/http2/x/same/interrupt", true, true): failure
java.lang.AssertionError: expected [true] but found [false]
	at org.testng.Assert.fail(Assert.java:94)
	at org.testng.Assert.failNotEquals(Assert.java:496)
	at org.testng.Assert.assertTrue(Assert.java:42)
	at org.testng.Assert.assertTrue(Assert.java:52)
	at CancelRequestTest.testGetSendAsync(CancelRequestTest.java:307)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:564)
	at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:85)
	at org.testng.internal.Invoker.invokeMethod(Invoker.java:639)
	at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:821)
	at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1131)
	at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:124)
	at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:108)
	at org.testng.TestRunner.privateRun(TestRunner.java:773)
	at org.testng.TestRunner.run(TestRunner.java:623)
	at org.testng.SuiteRunner.runTest(SuiteRunner.java:357)
	at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:352)
	at org.testng.SuiteRunner.privateRun(SuiteRunner.java:310)
	at org.testng.SuiteRunner.run(SuiteRunner.java:259)
	at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52)
	at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:86)
	at org.testng.TestNG.runSuitesSequentially(TestNG.java:1185)
	at org.testng.TestNG.runSuitesLocally(TestNG.java:1110)
	at org.testng.TestNG.run(TestNG.java:1018)
	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:94)
	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:54)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:564)
	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
	at java.base/java.lang.Thread.run(Thread.java:832)

Comments
Changeset: 710653ce Author: Daniel Fuchs <dfuchs@openjdk.org> Date: 2022-03-15 12:59:54 +0000 URL: https://git.openjdk.java.net/jdk/commit/710653ce1856d13161ae1786d7c5f71997536e78
15-03-2022

A pull request was submitted for review. URL: https://git.openjdk.java.net/jdk/pull/7776 Date: 2022-03-10 16:44:53 +0000
10-03-2022

Different failure mode but seems related: WARNING: exception caught in HttpTestHandler::handle java.io.IOException: An established connection was aborted by the software in your host machine java.io.IOException: An established connection was aborted by the software in your host machine at java.base/sun.nio.ch.SocketDispatcher.write0(Native Method) at java.base/sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:54) at java.base/sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:132) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:97) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:53) at java.base/sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:532) at jdk.httpserver/sun.net.httpserver.Request$WriteStream.write(Request.java:391) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.writeChunk(ChunkedOutputStream.java:125) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.flush(ChunkedOutputStream.java:159) at jdk.httpserver/sun.net.httpserver.PlaceholderOutputStream.flush(ExchangeImpl.java:469) at CancelRequestTest$HTTPSlowHandler.handle(CancelRequestTest.java:608) at HttpServerAdapters$HttpTestHandler.doHandle(HttpServerAdapters.java:350) at HttpServerAdapters$HttpTestHandler.lambda$toHttpHandler$0(HttpServerAdapters.java:343) at jdk.httpserver/com.sun.net.httpserver.Filter$Chain.doFilter(Filter.java:95) at jdk.httpserver/sun.net.httpserver.AuthFilter.doFilter(AuthFilter.java:82) at jdk.httpserver/com.sun.net.httpserver.Filter$Chain.doFilter(Filter.java:98) at jdk.httpserver/sun.net.httpserver.ServerImpl$Exchange$LinkHandler.handle(ServerImpl.java:703) at jdk.httpserver/com.sun.net.httpserver.Filter$Chain.doFilter(Filter.java:95) at jdk.httpserver/sun.net.httpserver.ServerImpl$Exchange.run(ServerImpl.java:670) at jdk.httpserver/sun.net.httpserver.ServerImpl$DefaultExecutor.execute(ServerImpl.java:159) at jdk.httpserver/sun.net.httpserver.ServerImpl$Dispatcher.handle(ServerImpl.java:447) at jdk.httpserver/sun.net.httpserver.ServerImpl$Dispatcher.run(ServerImpl.java:413) at java.base/java.lang.Thread.run(Thread.java:833) Suppressed: java.io.IOException: An established connection was aborted by the software in your host machine at java.base/sun.nio.ch.SocketDispatcher.write0(Native Method) at java.base/sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:54) at java.base/sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:132) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:97) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:53) at java.base/sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:532) at jdk.httpserver/sun.net.httpserver.Request$WriteStream.write(Request.java:391) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.writeChunk(ChunkedOutputStream.java:125) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.flush(ChunkedOutputStream.java:159) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.close(ChunkedOutputStream.java:134) at jdk.httpserver/sun.net.httpserver.PlaceholderOutputStream.close(ExchangeImpl.java:474) at CancelRequestTest$HTTPSlowHandler.handle(CancelRequestTest.java:599) ... 12 more
10-06-2021

New failure observed: config CancelRequestTest.beforeMethod(org.testng.TestRunner@7b1c0301): success [12 s, 421 ms, 709216 ns] testPostSendAsync(https://localhost:49371/https2/x/same/interrupt/post, true, true) response: jdk.internal.net.http.common.MinimalFuture@22b60fd8[Not completed, 1 dependents] (id=5663) cf1: jdk.internal.net.http.common.MinimalFuture@3e4ce72[Not completed, 1 dependents] (id=5664) cf2: jdk.internal.net.http.common.MinimalFuture@27b159a2[Not completed] (id=5665) response after cancel: jdk.internal.net.http.common.MinimalFuture@22b60fd8[Not completed, 1 dependents] (id=5663) cf1 after cancel: jdk.internal.net.http.common.MinimalFuture@3e4ce72[Not completed, 1 dependents] (id=5664) cf2 after cancel: jdk.internal.net.http.common.MinimalFuture@27b159a2[Not completed] (id=5665) Http2TestContext::handle Http2TestExchangeImpl: Http2TestExchangeImpl@33426f07 HTTPSlowHandler received request to https://localhost:49371/https2/x/same/interrupt/post waiting for completion on: java.util.concurrent.CompletableFuture@1eff985d[Completed normally] Cancelling from Thread[pool-1-thread-2,5,MainThreadGroup] HTTPSlowHandler: unexpected exception: java.io.IOException: closed HTTPSlowHandler reply sent: https://localhost:49371/https2/x/same/interrupt/post WARNING: exception caught in Http2Chain::doFilter java.io.IOException: closed java.io.IOException: closed at BodyOutputStream.write(BodyOutputStream.java:82) at java.base/java.io.OutputStream.write(OutputStream.java:127) at CancelRequestTest$HTTPSlowHandler.handle(CancelRequestTest.java:607) at HttpServerAdapters$HttpChain$Http2Chain.doFilter(HttpServerAdapters.java:432) at HttpServerAdapters$HttpTestServer$Http2TestContext.handle(HttpServerAdapters.java:611) at HttpServerAdapters$HttpTestHandler.doHandle(HttpServerAdapters.java:349) at HttpServerAdapters$HttpTestHandler.lambda$toHttp2Handler$1(HttpServerAdapters.java:345) at Http2TestServerConnection.handleRequest(Http2TestServerConnection.java:682) at Http2TestServerConnection.lambda$createStream$3(Http2TestServerConnection.java:633) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1130) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:630) at java.base/java.lang.Thread.run(Thread.java:831) WARNING: exception caught in HttpTestHandler::handle java.io.IOException: closed java.io.IOException: closed at BodyOutputStream.write(BodyOutputStream.java:82) at java.base/java.io.OutputStream.write(OutputStream.java:127) at CancelRequestTest$HTTPSlowHandler.handle(CancelRequestTest.java:607) at HttpServerAdapters$HttpChain$Http2Chain.doFilter(HttpServerAdapters.java:432) at HttpServerAdapters$HttpTestServer$Http2TestContext.handle(HttpServerAdapters.java:611) at HttpServerAdapters$HttpTestHandler.doHandle(HttpServerAdapters.java:349) at HttpServerAdapters$HttpTestHandler.lambda$toHttp2Handler$1(HttpServerAdapters.java:345) at Http2TestServerConnection.handleRequest(Http2TestServerConnection.java:682) at Http2TestServerConnection.lambda$createStream$3(Http2TestServerConnection.java:633) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1130) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:630) at java.base/java.lang.Thread.run(Thread.java:831) java.util.concurrent.CompletionException: java.util.concurrent.CancellationException: Request cancelled Got expected exception: java.util.concurrent.ExecutionException: java.util.concurrent.CancellationException: Request cancelled Got expected exception: java.util.concurrent.ExecutionException: java.util.concurrent.CancellationException: Request cancelled Got expected exception: java.util.concurrent.CancellationException: Request cancelled cause: java.io.IOException: Stream 19 cancelled response: jdk.internal.net.http.common.MinimalFuture@23c2c36f[Not completed, 1 dependents] (id=5694) cf1: jdk.internal.net.http.common.MinimalFuture@3198c000[Not completed, 1 dependents] (id=5695) cf2: jdk.internal.net.http.common.MinimalFuture@14aa1f1f[Not completed] (id=5696) response after cancel: jdk.internal.net.http.common.MinimalFuture@23c2c36f[Not completed, 1 dependents] (id=5694) cf1 after cancel: jdk.internal.net.http.common.MinimalFuture@3198c000[Not completed, 1 dependents] (id=5695) cf2 after cancel: jdk.internal.net.http.common.MinimalFuture@14aa1f1f[Not completed] (id=5696) cancelled jdk.internal.net.http.common.MinimalFuture@3e4ce72[Completed exceptionally: java.util.concurrent.CompletionException: java.util.concurrent.CancellationException: Request cancelled] (id=5664) waiting for completion on: java.util.concurrent.CompletableFuture@5571bc8c[Completed normally] java.util.concurrent.CompletionException: java.io.EOFException: EOF reached while reading Cancelling from Thread[pool-1-thread-3,5,MainThreadGroup] cancelled jdk.internal.net.http.common.MinimalFuture@3198c000[Completed exceptionally: java.util.concurrent.CompletionException: java.io.EOFException: EOF reached while reading] (id=5695) Got expected exception: java.util.concurrent.ExecutionException: java.io.EOFException: EOF reached while reading test CancelRequestTest.testPostSendAsync("https://localhost:49371/https2/x/same/interrupt", true, true): failure java.lang.AssertionError: expected [true] but found [false] at org.testng.Assert.fail(Assert.java:94) at org.testng.Assert.failNotEquals(Assert.java:496) at org.testng.Assert.assertTrue(Assert.java:42) at org.testng.Assert.assertTrue(Assert.java:52) at CancelRequestTest.testPostSendAsync(CancelRequestTest.java:411) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:78) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:567) at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:85) at org.testng.internal.Invoker.invokeMethod(Invoker.java:639) at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:821) at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1131) at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:124) at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:108) at org.testng.TestRunner.privateRun(TestRunner.java:773) at org.testng.TestRunner.run(TestRunner.java:623) at org.testng.SuiteRunner.runTest(SuiteRunner.java:357) at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:352) at org.testng.SuiteRunner.privateRun(SuiteRunner.java:310) at org.testng.SuiteRunner.run(SuiteRunner.java:259) at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52) at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:86) at org.testng.TestNG.runSuitesSequentially(TestNG.java:1185) at org.testng.TestNG.runSuitesLocally(TestNG.java:1110) at org.testng.TestNG.run(TestNG.java:1018) at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:94) at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:54) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:78) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:567) at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127) at java.base/java.lang.Thread.run(Thread.java:831)
03-12-2020

The test expected a CancellationException, but got a "java.io.IOException: connection closed locally" instead. This could happen if the current thread was interrupted while reading/writing; however the implementation is taking great care to always wrap such exceptions in a CancellationException if the request was cancelled; there could be a race condition - or some other issue - which caused the IOException to be relayed too early without being wrapped. Another possibility would be if the server closed the connection arbitrarily - but in that case we shouldn't see the message "connection closed locally"; This is rare and intermittent, and the consequences (getting IOException after cancel instead of CancellationException) after the request was cancelled by the caller should be benign.
14-10-2020

With a little more context: config CancelRequestTest.beforeMethod(org.testng.TestRunner@19583b9b): success [1 s, 756 ms, 913475 ns] testGetSendAsync(http://localhost:45759/http2/x/same/interrupt/get, true, true) response: jdk.internal.net.http.common.MinimalFuture@442a2be6[Not completed, 1 dependents] (id=760) cf1: jdk.internal.net.http.common.MinimalFuture@2895b896[Not completed, 1 dependents] (id=761) cf2: jdk.internal.net.http.common.MinimalFuture@57638c0c[Not completed] (id=762) client delay: 23 Server wrote 12 bytes HTTPSlowHandler: unexpected exception: java.io.IOException: Broken pipe HTTPSlowHandler reply sent: /http1/x/same/interrupt/get WARNING: exception caught in HttpTestHandler::handle java.io.IOException: Broken pipe java.io.IOException: Broken pipe at java.base/sun.nio.ch.FileDispatcherImpl.write0(Native Method) at java.base/sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:62) at java.base/sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:113) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:79) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:50) at java.base/sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:502) at jdk.httpserver/sun.net.httpserver.Request$WriteStream.write(Request.java:391) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.writeChunk(ChunkedOutputStream.java:125) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.flush(ChunkedOutputStream.java:159) at jdk.httpserver/sun.net.httpserver.PlaceholderOutputStream.flush(ExchangeImpl.java:470) at CancelRequestTest$HTTPSlowHandler.handle(CancelRequestTest.java:608) at HttpServerAdapters$HttpTestHandler.doHandle(HttpServerAdapters.java:349) at HttpServerAdapters$HttpTestHandler.lambda$toHttpHandler$0(HttpServerAdapters.java:342) at jdk.httpserver/com.sun.net.httpserver.Filter$Chain.doFilter(Filter.java:93) at jdk.httpserver/sun.net.httpserver.AuthFilter.doFilter(AuthFilter.java:82) at jdk.httpserver/com.sun.net.httpserver.Filter$Chain.doFilter(Filter.java:96) at jdk.httpserver/sun.net.httpserver.ServerImpl$Exchange$LinkHandler.handle(ServerImpl.java:692) at jdk.httpserver/com.sun.net.httpserver.Filter$Chain.doFilter(Filter.java:93) at jdk.httpserver/sun.net.httpserver.ServerImpl$Exchange.run(ServerImpl.java:664) at jdk.httpserver/sun.net.httpserver.ServerImpl$DefaultExecutor.execute(ServerImpl.java:159) at jdk.httpserver/sun.net.httpserver.ServerImpl$Dispatcher.handle(ServerImpl.java:442) at jdk.httpserver/sun.net.httpserver.ServerImpl$Dispatcher.run(ServerImpl.java:408) at java.base/java.lang.Thread.run(Thread.java:832) Suppressed: java.io.IOException: Broken pipe at java.base/sun.nio.ch.FileDispatcherImpl.write0(Native Method) at java.base/sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:62) at java.base/sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:113) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:79) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:50) at java.base/sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:502) at jdk.httpserver/sun.net.httpserver.Request$WriteStream.write(Request.java:391) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.writeChunk(ChunkedOutputStream.java:125) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.flush(ChunkedOutputStream.java:159) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.close(ChunkedOutputStream.java:134) at jdk.httpserver/sun.net.httpserver.PlaceholderOutputStream.close(ExchangeImpl.java:475) at CancelRequestTest$HTTPSlowHandler.handle(CancelRequestTest.java:599) ... 12 more HTTPSlowHandler received request to /http1/x/same/interrupt/get HTTPSlowHandler: unexpected exception: java.io.IOException: Broken pipe HTTPSlowHandler reply sent: /http1/x/same/interrupt/get WARNING: exception caught in HttpTestHandler::handle java.io.IOException: Broken pipe java.io.IOException: Broken pipe at java.base/sun.nio.ch.FileDispatcherImpl.write0(Native Method) at java.base/sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:62) at java.base/sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:113) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:79) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:50) at java.base/sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:502) at jdk.httpserver/sun.net.httpserver.Request$WriteStream.write(Request.java:391) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.writeChunk(ChunkedOutputStream.java:125) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.flush(ChunkedOutputStream.java:159) at jdk.httpserver/sun.net.httpserver.PlaceholderOutputStream.flush(ExchangeImpl.java:470) at CancelRequestTest$HTTPSlowHandler.handle(CancelRequestTest.java:608) at HttpServerAdapters$HttpTestHandler.doHandle(HttpServerAdapters.java:349) at HttpServerAdapters$HttpTestHandler.lambda$toHttpHandler$0(HttpServerAdapters.java:342) at jdk.httpserver/com.sun.net.httpserver.Filter$Chain.doFilter(Filter.java:93) at jdk.httpserver/sun.net.httpserver.AuthFilter.doFilter(AuthFilter.java:82) at jdk.httpserver/com.sun.net.httpserver.Filter$Chain.doFilter(Filter.java:96) at jdk.httpserver/sun.net.httpserver.ServerImpl$Exchange$LinkHandler.handle(ServerImpl.java:692) at jdk.httpserver/com.sun.net.httpserver.Filter$Chain.doFilter(Filter.java:93) at jdk.httpserver/sun.net.httpserver.ServerImpl$Exchange.run(ServerImpl.java:664) at jdk.httpserver/sun.net.httpserver.ServerImpl$DefaultExecutor.execute(ServerImpl.java:159) at jdk.httpserver/sun.net.httpserver.ServerImpl$Dispatcher.handle(ServerImpl.java:442) at jdk.httpserver/sun.net.httpserver.ServerImpl$Dispatcher.run(ServerImpl.java:408) at java.base/java.lang.Thread.run(Thread.java:832) Suppressed: java.io.IOException: Broken pipe at java.base/sun.nio.ch.FileDispatcherImpl.write0(Native Method) at java.base/sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:62) at java.base/sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:113) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:79) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:50) at java.base/sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:502) at jdk.httpserver/sun.net.httpserver.Request$WriteStream.write(Request.java:391) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.writeChunk(ChunkedOutputStream.java:125) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.flush(ChunkedOutputStream.java:159) at jdk.httpserver/sun.net.httpserver.ChunkedOutputStream.close(ChunkedOutputStream.java:134) at jdk.httpserver/sun.net.httpserver.PlaceholderOutputStream.close(ExchangeImpl.java:475) at CancelRequestTest$HTTPSlowHandler.handle(CancelRequestTest.java:599) ... 12 more java.util.concurrent.CompletionException: java.util.concurrent.CancellationException: Request cancelled response after cancel: jdk.internal.net.http.common.MinimalFuture@442a2be6[Completed exceptionally: java.util.concurrent.CompletionException: java.util.concurrent.CancellationException: Request cancelled] (id=760) cf1 after cancel: jdk.internal.net.http.common.MinimalFuture@2895b896[Completed exceptionally: java.util.concurrent.CompletionException: java.util.concurrent.CancellationException: Request cancelled] (id=761) cf2 after cancel: jdk.internal.net.http.common.MinimalFuture@57638c0c[Completed exceptionally: java.util.concurrent.CompletionException: java.util.concurrent.CancellationException: Request cancelled] (id=762) Got expected exception: java.util.concurrent.ExecutionException: java.util.concurrent.CancellationException: Request cancelled Got expected exception: java.util.concurrent.ExecutionException: java.util.concurrent.CancellationException: Request cancelled CancellationException cause: java.util.concurrent.ExecutionException: java.util.concurrent.CancellationException: Request cancelled Got expected exception: java.util.concurrent.CancellationException: Request cancelled cause: java.io.IOException: Can't get stream 1 response: jdk.internal.net.http.common.MinimalFuture@584a8560[Not completed, 1 dependents] (id=821) cf1: jdk.internal.net.http.common.MinimalFuture@4d2ae094[Not completed, 1 dependents] (id=822) cf2: jdk.internal.net.http.common.MinimalFuture@487eb0af[Not completed] (id=823) client delay: 11 java.util.concurrent.CompletionException: java.io.IOException: connection closed locally response after cancel: jdk.internal.net.http.common.MinimalFuture@584a8560[Completed exceptionally: java.util.concurrent.CompletionException: java.io.IOException: connection closed locally] (id=821) cf1 after cancel: jdk.internal.net.http.common.MinimalFuture@4d2ae094[Completed exceptionally: java.util.concurrent.CompletionException: java.io.IOException: connection closed locally] (id=822) cf2 after cancel: jdk.internal.net.http.common.MinimalFuture@487eb0af[Completed exceptionally: java.util.concurrent.CompletionException: java.io.IOException: connection closed locally] (id=823) Got expected exception: java.util.concurrent.ExecutionException: java.io.IOException: connection closed locally test CancelRequestTest.testGetSendAsync("http://localhost:45759/http2/x/same/interrupt", true, true): failure java.lang.AssertionError: expected [true] but found [false] at org.testng.Assert.fail(Assert.java:94) at org.testng.Assert.failNotEquals(Assert.java:496) at org.testng.Assert.assertTrue(Assert.java:42) at org.testng.Assert.assertTrue(Assert.java:52) at CancelRequestTest.testGetSendAsync(CancelRequestTest.java:307) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:564) at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:85) at org.testng.internal.Invoker.invokeMethod(Invoker.java:639) at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:821) at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1131) at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:124) at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:108) at org.testng.TestRunner.privateRun(TestRunner.java:773) at org.testng.TestRunner.run(TestRunner.java:623) at org.testng.SuiteRunner.runTest(SuiteRunner.java:357) at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:352) at org.testng.SuiteRunner.privateRun(SuiteRunner.java:310) at org.testng.SuiteRunner.run(SuiteRunner.java:259) at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52) at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:86) at org.testng.TestNG.runSuitesSequentially(TestNG.java:1185) at org.testng.TestNG.runSuitesLocally(TestNG.java:1110) at org.testng.TestNG.run(TestNG.java:1018) at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:94) at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:54) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:564) at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127) at java.base/java.lang.Thread.run(Thread.java:832)
14-10-2020