activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeremy Levy <jel...@gmail.com>
Subject Re: Patch to disable all Queues
Date Wed, 01 Jun 2011 14:09:29 GMT
Slightly updated patch, had a typo.

On Wed, Jun 1, 2011 at 9:51 AM, Jeremy Levy <jelevy@gmail.com> wrote:

> We currently deploy our ActiveMQ enabled Message Driven Beans along with
> our larger application inside of an EAR file.  This ear file is then
> deployed across multiple application servers.  However we only wanted
> consumers to be active on certain dedicated servers.  I wasn't able to find
> a solution within ActiveMQ that allows us to globally turn off consumers at
> deployment.  For a while we were tweaking the consumers via JMX but that was
> problematic and could only be done after the consumer was activated and
> started processing.
>
> I built our own activemq-rar-5.4.2.rar with the following modifications:
>
> In ActiveMQResourceAdapter.java, public void
> endpointActivation(MessageEndpointFactory endpointFactory, ActivationSpec
> activationSpec)
>
> Before creating the worker and checking to see if it previously activated a
> quick system property check:
>
> if (!Boolean.valueOf(System.getProperty("activemq.endpoints.disabled",
> "false"))) {...
>
>
> If true, dont' actually enable any queues etc.  I'm not sure this is the
> best method but it seems to be working.  I've included a patch for the 5.4.2
> branch.  I can prepare one for the trunk if the developers think this would
> be a worthwhile contribution.
>
> Jeremy
>
> --
> Jeremy Levy
>



-- 
Jeremy Levy

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