RFR: 8358588: ThreadSnapshot.ThreadLock should be static nested class

Aleksey Shipilev shade at openjdk.org
Wed Jun 4 13:19:26 UTC 2025


SonarCloud points out that ThreadLock class introduced by [JDK-8357650](https://bugs.openjdk.org/browse/JDK-8357650) can be turned into static nested class. I don't think this shows any real bug yet, as unreferenced enclosing class reference gets nowhere. But it would be nice to be extra crisp here.

Additional testing:
 - [ ] Linux x86_64 server fastdebug, `serviceability/`

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

Commit messages:
 - Fix

Changes: https://git.openjdk.org/jdk/pull/25638/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=25638&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8358588
  Stats: 1 line in 1 file changed: 0 ins; 0 del; 1 mod
  Patch: https://git.openjdk.org/jdk/pull/25638.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/25638/head:pull/25638

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


More information about the core-libs-dev mailing list