On Thu, 5 Feb 2026 13:56:41 GMT, Volkan Yazici <[email protected]> wrote:
>> I'd expect the default OS specific connection timeout to be around 2 mins on >> unix platforms. So if you pass a timeout that's largely lesser than that you >> will practically never see the `ConnectException`. It may still happen if >> the selector/poller thread is paused for too long, so it's good to cater for >> that. > >> OK - this is because the OS specific timeout kicks in. So you might get a >> `ConnectException` if the timeout you provide to connect() exceeds the >> OS/platform specific timeout. Otherwise you get the `SocketTimeoutException`. > > Could you explain this a little bit more, please? Because, in the Windows > host JTreg log I privately shared with you, there is the `elapsed time > (seconds): 0.903` line. That is, `connect(..., 5000)` threw > `ConnectionException` in less than 1s, which is less than both the timeout I > provide (i.e., 5s) and the OS defaults to. Am I missing something? I was speaking about unix platforms behaviour here. The test excludes windows platforms. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/29431#discussion_r2769406612
