On Fri, 29 Nov 2024 15:29:06 GMT, Volkan Yazıcı <d...@openjdk.org> wrote:
>> This PR, addressing 8343791, changes `Socket::connect()` methods to close >> the `Socket` in the event that the connection cannot be established, the >> timeout expires before the connection is established, or the socket address >> is unresolved. >> >> `tier3` tests pass against the 9f00f61d3b7fa42a5e23a04f80bb4bb1a2076ef2. > > Volkan Yazıcı has updated the pull request incrementally with two additional > commits since the last revision: > > - Improve Javadoc > - Match `UHE` message in `Socket` and `SocketImpl` > > This discrepancy was causing following tests to fail: > > - javax/xml/jaxp/unittest/common/dtd/DOMTest.java > - javax/xml/jaxp/unittest/common/dtd/SAXTest.java > - javax/xml/jaxp/unittest/common/catalog/SAXTest.java > - javax/xml/jaxp/unittest/common/catalog/DOMTest.java Marked as reviewed by dfuchs (Reviewer). src/java.base/share/classes/java/net/Socket.java line 664: > 662: > 663: if (epoint.isUnresolved()) { > 664: var uhe = new UnknownHostException(epoint.getHostName()); In this instance, I believe reverting to the same message as was thrown before and reconciling Socket with SocketImpl is the right call. The change to the exception message was somewhat gratuitous. Since it makes several tests fail, let's avoid that. ------------- PR Review: https://git.openjdk.org/jdk/pull/22160#pullrequestreview-2470195551 PR Review Comment: https://git.openjdk.org/jdk/pull/22160#discussion_r1863701395