JNDI `DnsClient` has a finalize method to close its internal datagram channel selector. The change proposed here replaces it with a cleaner to close the selector once the `DnsClient` instance becomes phantom reachable.
The change was tested with `jdk-tier1` to `jdk-tier3` test sets which showed no failures. ------------- Commit messages: - 8302845: Replace finalizer usage in JNDI DNS provider with Cleaner Changes: https://git.openjdk.org/jdk/pull/13837/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=13837&range=00 Issue: https://bugs.openjdk.org/browse/JDK-8302845 Stats: 26 lines in 3 files changed: 12 ins; 10 del; 4 mod Patch: https://git.openjdk.org/jdk/pull/13837.diff Fetch: git fetch https://git.openjdk.org/jdk.git pull/13837/head:pull/13837 PR: https://git.openjdk.org/jdk/pull/13837