You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by bansalp <bp...@gmail.com> on 2014/09/17 15:21:01 UTC

How to notify Clients if ActiveMQ broker is down?

Hi,

I want clients to get notification whenever my activemq broker is down for
any reason.

How can this be done? Is there any callback mechanism?



--
View this message in context: http://activemq.2283324.n4.nabble.com/How-to-notify-Clients-if-ActiveMQ-broker-is-down-tp4685662.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: How to notify Clients if ActiveMQ broker is down?

Posted by bansalp <bp...@gmail.com>.
I am trying to use TransportListener.

When will onException() method will be called ?

Thanks,




--
View this message in context: http://activemq.2283324.n4.nabble.com/How-to-notify-Clients-if-ActiveMQ-broker-is-down-tp4685662p4686152.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: How to notify Clients if ActiveMQ broker is down?

Posted by bansalp <bp...@gmail.com>.
Can you point me to some of the options?



--
View this message in context: http://activemq.2283324.n4.nabble.com/How-to-notify-Clients-if-ActiveMQ-broker-is-down-tp4685662p4685668.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: How to notify Clients if ActiveMQ broker is down?

Posted by Timothy Bish <ta...@gmail.com>.
On 09/17/2014 10:29 AM, bansalp wrote:
> I just want a way so that client can know that broker is down.
>
> Problem I am trying to solve is using activemq, there are two other
> components, so if there is some failure than It can be because of one of the
> component failing. So I need a mechanism to know that whether its broker
> which fails or something else.
>
>
>
> --
> View this message in context: http://activemq.2283324.n4.nabble.com/How-to-notify-Clients-if-ActiveMQ-broker-is-down-tp4685662p4685666.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>
It's up to you to craft a solution specific to your architecture.

-- 
Tim Bish
Sr Software Engineer | RedHat Inc.
tim.bish@redhat.com | www.redhat.com
skype: tabish121 | twitter: @tabish121
blog: http://timbish.blogspot.com/


Re: How to notify Clients if ActiveMQ broker is down?

Posted by bansalp <bp...@gmail.com>.
I just want a way so that client can know that broker is down. 

Problem I am trying to solve is using activemq, there are two other
components, so if there is some failure than It can be because of one of the
component failing. So I need a mechanism to know that whether its broker
which fails or something else.



--
View this message in context: http://activemq.2283324.n4.nabble.com/How-to-notify-Clients-if-ActiveMQ-broker-is-down-tp4685662p4685666.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: How to notify Clients if ActiveMQ broker is down?

Posted by bansalp <bp...@gmail.com>.
Is TransportListener best way to do this? Is there any better method. 

(Its a master slave architecture, so if primary broker goes down then client
automatically connects to failover broker, but I still want clients to know
that broker was down)



--
View this message in context: http://activemq.2283324.n4.nabble.com/How-to-notify-Clients-if-ActiveMQ-broker-is-down-tp4685662p4685776.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: How to notify Clients if ActiveMQ broker is down?

Posted by Timothy Bish <ta...@gmail.com>.
On 09/17/2014 09:21 AM, bansalp wrote:
> Hi,
>
> I want clients to get notification whenever my activemq broker is down for
> any reason.
>
> How can this be done? Is there any callback mechanism?
>
>
>
> --
> View this message in context: http://activemq.2283324.n4.nabble.com/How-to-notify-Clients-if-ActiveMQ-broker-is-down-tp4685662.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>
Depends on what sort of notification you want and what the client's are 
using to connect.  A normal ActiveMQ OpenWire client can use the 
TransportListener to get connection events when using Failover based 
connections:

http://sensatic.net/activemq/fast-producer-failover-with-activemq.html

-- 
Tim Bish
Sr Software Engineer | RedHat Inc.
tim.bish@redhat.com | www.redhat.com
skype: tabish121 | twitter: @tabish121
blog: http://timbish.blogspot.com/