Lingo 1.3 lingering threads won’t let Java or Tomcat die
I was working with Lingo (a RPC over JMS mechanism for Spring) last week and we uncovered an issue in which Lingo threads were not closing properly. The problem was uncovered since our JUnit tests were running fine, but any application which used a main() method had to call System.exit() to finish, which is ugly. Additionally, our Tomcat server application would not close, there were a number of threads left around even after the Spring context and ActiveMQ broker had been taken down.
With a little effort I isolated the code to a mistake in the Lingo MultiplexingRequestor. The MultiplexingRequestor uses threadpool internally, and the close() method is not overridden, which causes the threadpool (and attached threads) to linger indefinitely.
The bug and solution code has been filed as LINGO-44. To use this, simply copy the MultiplexingRequestor to your local project and ensure the updated code comes *ahead* of lingo-1.3.jar in your classpath.
September 28th, 2007 at 9:58 pm
Hello
Very much for a long time searched for article on this theme.Thanks.
good by