RFR: JDK-8295756 Improve NonLocalRegistry Manual Test Process [v4]

Bill Huang bhuang at openjdk.org
Mon Nov 28 17:57:28 UTC 2022


On Mon, 28 Nov 2022 13:56:29 GMT, Alan Bateman <alanb at 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


More information about the serviceability-dev mailing list