You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by mtod <mt...@thetods.net> on 2015/12/28 23:58:52 UTC

suppress error from Camel Route on slave

I'm running ActiveMQ 5.13 on a leveldb cluster.
My ActiveMQ.xml config contains a Camel route in an include file.

	<import resource="ESBRoute1.xml"/>

I route xml from one queue to a topic but when slave is in standby mode I
keep getting this error :

INFO   | jvm 1    | 2015/12/28 18:10:26 | ERROR | Could not refresh JMS
Connection for destination 'esb.*' - retrying using
FixedBackOff{interval=5000, currentAttempts=181, maxAttempts=unlimited}.
Cause: Could not create Transport. Reason: java.io.IOException: Broker named
'localhost' does not exist.

Is there a way to suppress this error or Non-Error due to it being a slave?

Thanks

Mike




--
View this message in context: http://activemq.2283324.n4.nabble.com/suppress-error-from-Camel-Route-on-slave-tp4705457.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: suppress error from Camel Route on slave

Posted by Quinn Stevenson <qu...@pronoia-solutions.com>.
I had a similar setup in ActiveMQ 5.11.2 - but the route was a simple timer that wrote a log statement (amount other things).  When I ran this configuration in a Master/Slave configuration with a KahaDB store, the routes were only active one ActiveMQ instance at a time.

Can you post the camel.xml and the activemq.xml files?  I’d like to see what the differences are.

Quinn Stevenson
quinn@pronoia-solutions.com
(801) 244-7758



> On Dec 29, 2015, at 10:14 PM, Tim Bain <tb...@alumni.duke.edu> wrote:
> 
> Nope, never; I've only read about it here and on the wiki.  (I've used
> Camel, but never embedded in a broker.)  Sorry.  But others on this list
> have, so hopefully they can share first-hand knowledge.
> On Dec 29, 2015 10:22 AM, "Quinn Stevenson" <qu...@pronoia-solutions.com>
> wrote:
> 
>> Have you tried using the Broker Camel Component (
>> http://activemq.apache.org/broker-camel-component.html <
>> http://activemq.apache.org/broker-camel-component.html> )?  I thought
>> that it wouldn’t start the route unless the broker was running.
>> 
>> 
>> Quinn Stevenson
>> quinn@pronoia-solutions.com
>> (801) 244-7758
>> 
>> 
>> 
>>> On Dec 29, 2015, at 7:45 AM, mtod <mt...@thetods.net> wrote:
>>> 
>>> That's what I would like to happen but the question is how?
>>> 
>>> Thanks
>>> 
>>> Mike
>>> 
>>> 
>>> 
>>> --
>>> View this message in context:
>> http://activemq.2283324.n4.nabble.com/suppress-error-from-Camel-Route-on-slave-tp4705457p4705478.html
>>> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>> 
>> 


Re: suppress error from Camel Route on slave

Posted by Tim Bain <tb...@alumni.duke.edu>.
Nope, never; I've only read about it here and on the wiki.  (I've used
Camel, but never embedded in a broker.)  Sorry.  But others on this list
have, so hopefully they can share first-hand knowledge.
On Dec 29, 2015 10:22 AM, "Quinn Stevenson" <qu...@pronoia-solutions.com>
wrote:

> Have you tried using the Broker Camel Component (
> http://activemq.apache.org/broker-camel-component.html <
> http://activemq.apache.org/broker-camel-component.html> )?  I thought
> that it wouldn’t start the route unless the broker was running.
>
>
> Quinn Stevenson
> quinn@pronoia-solutions.com
> (801) 244-7758
>
>
>
> > On Dec 29, 2015, at 7:45 AM, mtod <mt...@thetods.net> wrote:
> >
> > That's what I would like to happen but the question is how?
> >
> > Thanks
> >
> > Mike
> >
> >
> >
> > --
> > View this message in context:
> http://activemq.2283324.n4.nabble.com/suppress-error-from-Camel-Route-on-slave-tp4705457p4705478.html
> > Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>
>

Re: suppress error from Camel Route on slave

Posted by Quinn Stevenson <qu...@pronoia-solutions.com>.
Have you tried using the Broker Camel Component ( http://activemq.apache.org/broker-camel-component.html <http://activemq.apache.org/broker-camel-component.html> )?  I thought that it wouldn’t start the route unless the broker was running.


Quinn Stevenson
quinn@pronoia-solutions.com
(801) 244-7758



> On Dec 29, 2015, at 7:45 AM, mtod <mt...@thetods.net> wrote:
> 
> That's what I would like to happen but the question is how?
> 
> Thanks
> 
> Mike
> 
> 
> 
> --
> View this message in context: http://activemq.2283324.n4.nabble.com/suppress-error-from-Camel-Route-on-slave-tp4705457p4705478.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Re: suppress error from Camel Route on slave

Posted by Tim Bain <tb...@alumni.duke.edu>.
I was suggesting that as an enhancement (for which a JIRA enhancement
request would need to be submitted if you think it would be useful).  I
don't know of a currently-implemented way to do that, though if one exists
then hopefully someone else will share how to do it.

Your original question was about how to suppress the logging.  You should
be able to disable that logger in the Log4J config, but first you'll have
to figure out which logger that is (I'd either grep the ActiveMQ source
code or Google for that text, or change the appender format to include the
logger name).  I also don't know what other logging (that you'd want) comes
out of that logger and would be lost if you turn it off.

Or you could adjust your process for monitoring your logs, by filtering
them through a grep -v.
On Dec 29, 2015 8:05 AM, "mtod" <mt...@thetods.net> wrote:

> That's what I would like to happen but the question is how?
>
> Thanks
>
> Mike
>
>
>
> --
> View this message in context:
> http://activemq.2283324.n4.nabble.com/suppress-error-from-Camel-Route-on-slave-tp4705457p4705478.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>

Re: suppress error from Camel Route on slave

Posted by mtod <mt...@thetods.net>.
That's what I would like to happen but the question is how?

Thanks

Mike



--
View this message in context: http://activemq.2283324.n4.nabble.com/suppress-error-from-Camel-Route-on-slave-tp4705457p4705478.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: suppress error from Camel Route on slave

Posted by Tim Bain <tb...@alumni.duke.edu>.
Maybe the broker should automatically suspend all embedded Camel routes
when it becomes a slave, and resume them when it becomes a master?
On Dec 28, 2015 4:18 PM, "mtod" <mt...@thetods.net> wrote:

> I'm running ActiveMQ 5.13 on a leveldb cluster.
> My ActiveMQ.xml config contains a Camel route in an include file.
>
>         <import resource="ESBRoute1.xml"/>
>
> I route xml from one queue to a topic but when slave is in standby mode I
> keep getting this error :
>
> INFO   | jvm 1    | 2015/12/28 18:10:26 | ERROR | Could not refresh JMS
> Connection for destination 'esb.*' - retrying using
> FixedBackOff{interval=5000, currentAttempts=181, maxAttempts=unlimited}.
> Cause: Could not create Transport. Reason: java.io.IOException: Broker
> named
> 'localhost' does not exist.
>
> Is there a way to suppress this error or Non-Error due to it being a slave?
>
> Thanks
>
> Mike
>
>
>
>
> --
> View this message in context:
> http://activemq.2283324.n4.nabble.com/suppress-error-from-Camel-Route-on-slave-tp4705457.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>