zookeeper-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Enrico Olivelli <eolive...@gmail.com>
Subject Re: Discover LEADER from JMX
Date Wed, 09 May 2018 11:50:59 GMT
So I am trying to create a patch in order to expose on JMX the id of the
current "leader" (on the JVM of a follower)

I am trying to find in ZK which is the variable which holds the ID of the
current leader.
I am new to the internal of QuorumPeer

Can someone give me some hint ?

Enrico

Il giorno mar 8 mag 2018 alle ore 10:08 Ansel Zandegran <
Ansel.Zandegran@infor.com> ha scritto:

> Hi,
> That is possible with 4 letter commands. We are using it now. In 3.5.x it
> is going to be removed in favour of admin server (embedded web server).
> We are running in an environment where it’s not possible to run JMX or
> embedded web servers.
>
> So I am wondering if there is another way? It would be nice to have this
> info as a znode.
>
> Best regards,
> Ansel
>
> > On 8 May 2018, at 09:55, Flavio Junqueira <fpj@apache.org> wrote:
> >
> > Hi Enrico,
> >
> > You can determine the state of a server it via 4-letter commands. Would
> that work for you?
> >
> > -Flavio
> >
> >> On 8 May 2018, at 09:09, Enrico Olivelli <eolivelli@gmail.com> wrote:
> >>
> >> Hi,
> >> is there any way to see in JMX which is the leader of a ZooKeeper
> cluster?
> >>
> >> My problem is: given access to any of the nodes of the cluster I want to
> >> know from JMX which is the current leader.
> >> It seems to me that this information is not available, you can know
> only if
> >> the local node is Leader or Follower.
> >>
> >> Cheers
> >> Enrico
> >
>
>

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