RFR: 8330814: Cleanups for KeepAliveCache tests

Christoph Langer clanger at openjdk.org
Mon Apr 22 11:14:48 UTC 2024


While working in that area I found some potential for cleanup of a few tests.

Most notably:

B5045306.java:
- does not need to run in othervm
- the executor service that it uses should be shut down eventually to free resources

B8291637.java:
- use just one instead of two test VM invocations
KeepAliveTimerThread.java:
call to grp.destroy() at the end is pointless (API is void & deprecated for removal)

Generally:
The deprecated URL constructor is used. It can be switched to the handy URIBuilder
Some more try with resources here and there

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

Commit messages:
 - Copyright year
 - JDK-8330814

Changes: https://git.openjdk.org/jdk/pull/18884/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=18884&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8330814
  Stats: 277 lines in 5 files changed: 114 ins; 57 del; 106 mod
  Patch: https://git.openjdk.org/jdk/pull/18884.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/18884/head:pull/18884

PR: https://git.openjdk.org/jdk/pull/18884


More information about the net-dev mailing list