[
https://issues.apache.org/jira/browse/BOOKKEEPER-696?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13808023#comment-13808023
]
Ivan Kelly commented on BOOKKEEPER-696:
---------------------------------------
As I've said before, I'd like to avoid these enums. They just make it far to
awkward to add new statistics, and then you need to have specialized classes
for each enum type etc etc. To me, this is no better than the nasty MXBean
stuff you have to do for JMX. When we spoke in August, Aniruddha said this was
to avoid metrics being taken which are hard to track down. This can be better
achieved by scoping all metrics by the class they're measured in. I've hacked
at this patch to not use enums[1]. The patch is incomplete due to another
issue, being that we shouldn't add another constructor parameter. There's
already too many variants. Instead we should create a Bookkeeper builder, which
we can add any new parameters too.
Usage like:
{code}
BookKeeper bk =
BookKeeper.forConfig(conf).setZooKeeper(zk).setStatsLogger(logger).build();
{code}
[1]
https://github.com/ivankelly/bookkeeper/commit/93215385cdaed257d5666b5a0556d8014ce31a2d
> stats collection on bookkeeper client
> -------------------------------------
>
> Key: BOOKKEEPER-696
> URL: https://issues.apache.org/jira/browse/BOOKKEEPER-696
> Project: Bookkeeper
> Issue Type: Sub-task
> Components: bookkeeper-client
> Reporter: Sijie Guo
> Assignee: Aniruddha
> Fix For: 4.3.0
>
> Attachments: 0001-client-stats-for-bookkeeper.patch
>
>
> Stats for bookkeeper client.
--
This message was sent by Atlassian JIRA
(v6.1#6144)