[jdk8u-dev] Integrated: 8312065: Socket.connect does not timeout when profiling
Long Yang
lyang at openjdk.org
Thu Jun 26 09:40:40 UTC 2025
On Thu, 21 Dec 2023 08:45:32 GMT, Long Yang <lyang at openjdk.org> wrote:
> Hi,
>
> This pull request contains the backport of [JDK-8312065](https://bugs.openjdk.org/browse/JDK-8312065), commit [1ce12c4](https://github.com/openjdk/jdk17u-dev/commit/1ce12c4f33d3d6905703d95df2574f4037dfd57d) from the [openjdk/jdk17u-dev](https://github.com/openjdk/jdk17u-dev) repository.
>
> I added the test `B8312065.java`. The test will fail on the JDK8 without my fix, and it will pass on the JDK8 containing my fix.
> This test relies on [libNativeThread](https://github.com/openjdk/jdk/blob/master/test/jdk/java/net/Socket/libNativeThread.c) to get the `OS thread ID` of the `Java threads`, and send signals to `OS threads`.
> The `libNativeThread` was introduced to test the fix for [JDK-8237858](https://bugs.openjdk.org/browse/JDK-8237858). However, `JDK-8237858` only exists in Java 10 and above. There is no `JDK-8237858` problem on Java 8, so `JDK-8237858` cannot be backported to Java 8.
> In order to use `libNativeThread`, I copied it to my backport.
>
> I ran all the `jtreg` tests in `test/jdk/java/net/ServerSocket`,`test/jdk/java/net/Socket`,`test/jdk/java/net/SocketOption`,`test/jdk/java/net/ipv6` on my host, all passed.
>
> Thanks!
This pull request has now been integrated.
Changeset: 8a5c3db3
Author: Long Yang <lyang at openjdk.org>
Committer: Denghui Dong <ddong at openjdk.org>
URL: https://git.openjdk.org/jdk8u-dev/commit/8a5c3db33936c703f50a0cab593a8474e7abafb7
Stats: 327 lines in 7 files changed: 244 ins; 0 del; 83 mod
8312065: Socket.connect does not timeout when profiling
Reviewed-by: phh
Backport-of: 1ce12c4f33d3d6905703d95df2574f4037dfd57d
-------------
PR: https://git.openjdk.org/jdk8u-dev/pull/410
More information about the jdk8u-dev
mailing list