The anonymous Thread object created in ShutdownHookManager is a GC root.
screenshot_1 shows how DN object be traced to the GC root.
It's not a problem in production.
It's a problem in test, especially when MiniDFSCluster starts/shutdowns many DNs, which could cause OutOfMemoryError.
screenshot_2 shows many DN objects are not GCed when run the test of