You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by Bram Van Dam <br...@intix.eu> on 2019/02/14 16:05:39 UTC

Four letter word command to get memory usage (patch included)

Hey folks,

I needed a way to keep track of individual ZK instances' memory usage
without using JMX, so I went and added a new four letter word: memo

Example usage:
# echo memo | nc 127.0.0.1 44011
Maximum memory: 514850816
Free memory: 479290568
Total memory: 514850816

This exposes the same data that ZOOKEEPER-716 logs, basically the
runtime's maximum/free/total memory.

Attached patch is against branch-3.4.13 as that's the version we're
currently using.

Any feedback is highly appreciated.
Should I go ahead and create a PR/Jira issue?

Thanks,

 - Bram

Re: Four letter word command to get memory usage (patch included)

Posted by Enrico Olivelli <eo...@gmail.com>.
It is also worth noting that we are also working on a new metrics
system and JVM information will be included in the new system.

https://issues.apache.org/jira/browse/ZOOKEEPER-3092

Enrico

Il giorno gio 14 feb 2019 alle ore 17:39 Andor Molnar
<an...@cloudera.com.invalid> ha scritto:
>
> Hi Bram,
>
> Thanks for the contribution. Please follow Enrico's instructions on how to
> officially contribute on the ZooKeeper project. Here's our guidelines:
> https://cwiki.apache.org/confluence/display/ZOOKEEPER/HowToContribute
>
> Additionally, 4lw has become deprecated, so we won't accept new features on
> that. You can add new Jetty command or JMX whichever suits you best. IMHO
> the best would be add to them both.
>
> Thanks,
> Andor
>
>
>
> On Thu, Feb 14, 2019 at 5:18 PM Enrico Olivelli <eo...@gmail.com> wrote:
>
> > Hi,
> > Can you please create a patch against master branch and create a PR in
> > github?
> >
> > Thank you
> >
> > Enrico
> >
> > Il giorno gio 14 feb 2019, 17:05 Bram Van Dam <br...@intix.eu> ha
> > scritto:
> >
> > > Hey folks,
> > >
> > > I needed a way to keep track of individual ZK instances' memory usage
> > > without using JMX, so I went and added a new four letter word: memo
> > >
> > > Example usage:
> > > # echo memo | nc 127.0.0.1 44011
> > > Maximum memory: 514850816
> > > Free memory: 479290568
> > > Total memory: 514850816
> > >
> > > This exposes the same data that ZOOKEEPER-716 logs, basically the
> > > runtime's maximum/free/total memory.
> > >
> > > Attached patch is against branch-3.4.13 as that's the version we're
> > > currently using.
> > >
> > > Any feedback is highly appreciated.
> > > Should I go ahead and create a PR/Jira issue?
> > >
> > > Thanks,
> > >
> > >  - Bram
> > >
> >

Re: Four letter word command to get memory usage (patch included)

Posted by Andor Molnar <an...@cloudera.com.INVALID>.
Hi Bram,

Thanks for the contribution. Please follow Enrico's instructions on how to
officially contribute on the ZooKeeper project. Here's our guidelines:
https://cwiki.apache.org/confluence/display/ZOOKEEPER/HowToContribute

Additionally, 4lw has become deprecated, so we won't accept new features on
that. You can add new Jetty command or JMX whichever suits you best. IMHO
the best would be add to them both.

Thanks,
Andor



On Thu, Feb 14, 2019 at 5:18 PM Enrico Olivelli <eo...@gmail.com> wrote:

> Hi,
> Can you please create a patch against master branch and create a PR in
> github?
>
> Thank you
>
> Enrico
>
> Il giorno gio 14 feb 2019, 17:05 Bram Van Dam <br...@intix.eu> ha
> scritto:
>
> > Hey folks,
> >
> > I needed a way to keep track of individual ZK instances' memory usage
> > without using JMX, so I went and added a new four letter word: memo
> >
> > Example usage:
> > # echo memo | nc 127.0.0.1 44011
> > Maximum memory: 514850816
> > Free memory: 479290568
> > Total memory: 514850816
> >
> > This exposes the same data that ZOOKEEPER-716 logs, basically the
> > runtime's maximum/free/total memory.
> >
> > Attached patch is against branch-3.4.13 as that's the version we're
> > currently using.
> >
> > Any feedback is highly appreciated.
> > Should I go ahead and create a PR/Jira issue?
> >
> > Thanks,
> >
> >  - Bram
> >
>

Re: Four letter word command to get memory usage (patch included)

Posted by Enrico Olivelli <eo...@gmail.com>.
Hi,
Can you please create a patch against master branch and create a PR in
github?

Thank you

Enrico

Il giorno gio 14 feb 2019, 17:05 Bram Van Dam <br...@intix.eu> ha
scritto:

> Hey folks,
>
> I needed a way to keep track of individual ZK instances' memory usage
> without using JMX, so I went and added a new four letter word: memo
>
> Example usage:
> # echo memo | nc 127.0.0.1 44011
> Maximum memory: 514850816
> Free memory: 479290568
> Total memory: 514850816
>
> This exposes the same data that ZOOKEEPER-716 logs, basically the
> runtime's maximum/free/total memory.
>
> Attached patch is against branch-3.4.13 as that's the version we're
> currently using.
>
> Any feedback is highly appreciated.
> Should I go ahead and create a PR/Jira issue?
>
> Thanks,
>
>  - Bram
>