On Thu, 24 Aug 2023 11:34:13 GMT, Kevin Walls <kev...@openjdk.org> wrote:
> Port clashes happening when several tests from test/jdk/sun/tools/jstatd run > at the same time on the same machine. > > There is logic in here for detecting this, but it's not working. > > We recently saw this fail with a port in use, and the failure is: > > [Jstatd-Thread] Could not bind //:33859/TestJstatdServer to RMI Registry > [Jstatd-Thread] java.rmi.NoSuchObjectException: no such object in table > > In JstatdTest.java, the isJstadReady() method (will correct that typo also) > checks for "Port already in use", which can be printed by TCPTransport.java. > But that is not what we see in this failure. > Should update its test to check for "Could not bind". > Should limit the retries also. "Cannot start jstatd. No free port found." might be too-specific an error to add here, it could be left as "Cannot start jstatd." ------------- PR Comment: https://git.openjdk.org/jdk/pull/15414#issuecomment-1691568067