On Mon, 28 Nov 2022 13:56:29 GMT, Alan Bateman <al...@openjdk.org> wrote:
>> Bill Huang has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Implemented review comments. > > test/jdk/javax/management/remote/nonLocalAccess/NonLocalJMXRemoteTest.java > line 167: > >> 165: >> Set.copyOf(Arrays.asList(InetAddress.getAllByName(myHostName))); >> 166: Set<InetAddress> hostAddrs = >> 167: >> Set.copyOf(Arrays.asList(InetAddress.getAllByName(host))); > > Is there a reason to change this from Set.of? This is a workaround for duplicate elements detected by Set.of(). On my localhost, InetAddress.getAllByName(localhost returns duplicate IPv6 addresses with different scoped id which is not counted during comparison. This change shouldn't impact the goal of these tests which is to verify that registry modification request from client side is prohibited. ------------- PR: https://git.openjdk.org/jdk/pull/10825