Description of problem: The following jboss-remote-naming thread ("naming-client-message-receiver-*") does not shutdown and still remains after calling "javax.naming.InitialContext#close()". ~~~ "naming-client-message-receiver-1-thread-1" daemon prio=10 tid=0x00007f7f24001800 nid=0xdebae waiting on condition [0x00007f7f8cd85000] java.lang.Thread.State: TIMED_WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for <0x0000000783119180> (a java.util.concurrent.SynchronousQueue$TransferStack) at java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:226) at java.util.concurrent.SynchronousQueue$TransferStack.awaitFulfill(SynchronousQueue.java:460) at java.util.concurrent.SynchronousQueue$TransferStack.transfer(SynchronousQueue.java:359) at java.util.concurrent.SynchronousQueue.poll(SynchronousQueue.java:942) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1068) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1130) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Locked ownable synchronizers: - None ~~~ How reproducible: Anytime. Steps to Reproduce: 1. Use the attached helloworld-jms-clearthreadpool.tar.gz, which is based on the jboss quickstart helloworld-jms 2. Take a thread dump after calling "javax.naming.InitialContext#close()" Actual results: "naming-client-message-receiver-*" does not shutdown after calling "javax.naming.InitialContext#close()" Expected results: "naming-client-message-receiver-*" shutdown after calling "javax.naming.InitialContext#close()".
Verified in EAP 6.4.0.DR11 / remote naming 1.0.10.Final-redhat-1. The thread naming-client-message-receiver-1-thread-1 no longer persists after the context is closed.