activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Fred Moore <>
Subject Trivial embedded broker not shutting down cleanly because of lingering threads
Date Wed, 13 Jan 2010 17:50:52 GMT
Hi folks,

we have a 5.3.0 embedded broker that refuses to shutdown cleanly because of
lingering threads.

We reproduced this with a very very basic configuration: with just vm & jmx
connectors, no producers and no consumers and and this extremely simple
main() program: that:

1\ Starts up an embedded broker

2\ Waits for the user to press a key

3\ Stops the broker

4\ Monitors (polling every few seconds) the number of lingering threads

What we experience is that after step 1\ (broker startup) this is the list
of active threads...

* [main] Group: main
* [ActiveMQ Scheduler] (Daemon) Group: main
* [ActiveMQ Data File Writer] (Daemon) Group: main
* [Timer-0] (Daemon) Group: main
* [JMX connector] (Daemon) Group: main

...but a long time (dozens of seconds) after step 3\ (broker shutdown) these
threads are still active:

* [main]  Group: main
* [ActiveMQ Scheduler] (Daemon) Group: main
* [Timer-0] (Daemon) Group: main

Q1\ Are we missing something obvious?
Q2\ Is there a better way to shutdown an embedded broker?
Q3\ Doing it the hard way via system.exit() is going to get us into worse
troubles? (data corruption & co)

Thanks in advance for your help.

The embedding was performed

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message