[ https://issues.apache.org/jira/browse/HBASE-19722?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16466655#comment-16466655 ]
Andrew Purtell commented on HBASE-19722: ---------------------------------------- Thanks for the patch! We want this to be optional, but making it an example seems wrong. It should live in the hbase-server module. Please move it. Optional doesn't mean example. I think {{hermitMode}} is a fun name but probably better just to name this boolean something like "active"? Otherwise people might be a little confused when looking at the code in places. I don't think you need to test for existence when marking a meter. Ahead of marking you always register the meter if it doesn't exist. One interesting aspect not yet handled is removing all of the metrics from stop(). The meta region can move around. It will be closed on one server and reopened on another. Ideally we don't want stale metrics hanging around on the old server. If the metrics API doesn't support this we should add it. > That's why I prefer not to put topk calculation to this coprocessor since it > has a performance impact on all meta table operations. I do think we need to do the top-K in the coprocessor. Or, at least, prune meters that are not in the top K. Otherwise the amount of heap consumed by these metrics can grow rather large depending on the number of unique clients. > Could we count the types of access Ideally, we should have - Counts for each type of operation - Aggregate count of all accesses by client identity - Counts for each type of operation by client identity See my comment above about pruning meters and state for rare clients. The combinatorics of the above means we'd have 10 or more metrics per unique client. > Implement a meta query statistics metrics source > ------------------------------------------------ > > Key: HBASE-19722 > URL: https://issues.apache.org/jira/browse/HBASE-19722 > Project: HBase > Issue Type: Sub-task > Reporter: Andrew Purtell > Assignee: Xu Cang > Priority: Major > Attachments: HBASE-19722.patch, HBASE-19722.patch.1, > HBASE-19722.patch.2, HBASE-19722.patch.3, HBASE-19722.patch.4, > HBASE-19722.patch.5 > > > Implement a meta query statistics metrics source, created whenever a > regionserver starts hosting meta, removed when meta hosting moves. Provide > views on top tables by request counts, top meta rowkeys by request count, top > clients making requests by their hostname. > Can be implemented as a coprocessor. -- This message was sent by Atlassian JIRA (v7.6.3#76005)