Description
On thread creation, current caller AccessControlContext is stored in Thread field inheritedAccessControlContext. If such AccessControlContext contains references to SessionPrincipal and ConnectionPrincipal instances (i.e. thread is created in Connection/Session), the corresponding Session and Connection objects are not GC'ed until Thread stops running. If Thread is created in implementation of java.util.concurrent. Executor it can be re-used and remain alive until Executor utilizes the thread. Potentially, such threads might stay alive until Broker JVM is shutdown.