Hi, Please find below a fix for: 8265367: [macos-aarch64] 3 java/net/httpclient/websocket tests fail with "IOException: No buffer space available"
The Pending* websocket tests create a server that accepts sockets to create a websocket, but never read data from the websocket in order to get the client side to block once the buffers are full. Unfortunately, the PendingOperations:cleanup methods was not called after each test methods invocations, causing sockets to leak and relying on the gc to cleanup. This caused an "IOException: No buffer space available" to be raised intermittently but reliably (1 run out of 50 in PendingTextPingClose). The fix makes sure that cleanup() is called appropriately after each test method invocation. It also tweaks PendingTextPingClose - which seemed to be failing more frequently - to use smaller send and receive buffers in order to reach the point at which the client bocks more quickly and avoid wasting system resources. ------------- Commit messages: - 8265367: [macos-aarch64] 3 java/net/httpclient/websocket tests fail with "IOException: No buffer space available" Changes: https://git.openjdk.java.net/jdk/pull/4222/files Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=4222&range=00 Issue: https://bugs.openjdk.java.net/browse/JDK-8265367 Stats: 135 lines in 14 files changed: 83 ins; 24 del; 28 mod Patch: https://git.openjdk.java.net/jdk/pull/4222.diff Fetch: git fetch https://git.openjdk.java.net/jdk pull/4222/head:pull/4222 PR: https://git.openjdk.java.net/jdk/pull/4222