RFR: 7903746: jtreg tests run extremely slow on some environments due to hostname lookups [v2]

Jonathan Gibbons jjg at openjdk.org
Tue Jul 2 23:36:29 UTC 2024


On Tue, 2 Jul 2024 15:09:33 GMT, Mark Sheppard <msheppar at openjdk.org> wrote:

>> Jaikiran Pai has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   include a self test to verify the presence of hostname in jtr file
>
> src/share/classes/com/sun/javatest/regtest/config/RegressionEnvironment.java line 61:
> 
>> 59: 
>> 60: 
>> 61:     private static final class LazyHostNameLookup {
> 
> LazyHostNameLookup infers a lookup deferred to the latest possible moment While 
> CachedHostName would convey a more appropriate semantics.
> 
> The rational for the change is the cost of a getCanonicalHostName invocation. However, InetAddress caches a getLocalHost
> call in a CachedLocalHost, which proves a mapping between a hostname and an InetAddress, but this cached value is not used in the getCanonicalHostName invocation. This seems strange that the cached values in InetAddress are not used more effectively for return a Hostname !!

@msheppar Is this worth a P4 followup RFE against InetAddress?

-------------

PR Review Comment: https://git.openjdk.org/jtreg/pull/204#discussion_r1663288941


More information about the jtreg-dev mailing list