activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Strachan" <>
Subject Re: Possible to Trade an In-Memory Queue between producer instances with embedded brokers?
Date Wed, 09 May 2007 15:24:15 GMT
On 5/9/07, Chris Hofstaedter <> wrote:
> I'm using 4.0.2 on various Windows machines.
> I've got a producer with an embedded broker with a
> MemoryPersistenceAdapter wrapped in a Log4J appender.  At times, the
> log4j.xml file may change in ways that affect the way the
> producer/embedded broker are configured.  When the change is detected,
> Log4J will destroy and recreate the appender instance.  This results in
> all of my in-queue messages being lost.
> Unfortunately, making the embedded broker actually persist to disk not
> an option for me.
> I'd like to find a way to swap the local memory queue from the embedded
> broker associated with the old producer instance to the one associated
> with the new (after config change) producer instance.

By default when using the vm:// transport the broker is started up
when the first connection is created; then destroyed when the last
connection closes. If you don't want that - e.g. you want to run an
embedded broker for the duration of your process - just explicitly
create one up front on startup...


View raw message