[ 
https://issues.apache.org/jira/browse/HBASE-6411?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13421732#comment-13421732
 ] 

Alex Baranau commented on HBASE-6411:
-------------------------------------

bq. The only usage before was through a guaranteed singleton that was only used 
on a single thread at a time (The master rpc thread or the replication thread)

I think this remained the same. MetricsRegistry is used in same MetricSources 
as private field, so it is shared only if the source is shared. Anyhow, using 
concurrent hash map makes more sense to me too, if we are ok with a bit more of 
modifying "copied" MetricsRegistry code.

bq. Maybe we should file a new hbase jira to make the BaseMetricsSource have a 
generic increment and decrement only

I think it existing methods are OK. We need also at list remove() method as 
well.

I think we are mostly on the same page! :)

One thing that catches my eye:
* in MasterMetrics we have metrics values (counters & gauges) managed by the 
class in hadoop-compat module, which exposes interface for working with them 
(MasterMetricsSource)
* while with ReplicationSink(Source)Metrics we have different pattern: metrics 
values managed in the classes created in hbase-server code and 
ReplicationSourceMetrics interface is empty (provides just generic methods from 
BaseMetricsSource)

by "managed" I mean defines interface for creating/changing values.


Should we probably unify that? E.g. push managing "sink.ageOfLastAppliedOp" 
metrics and such to xxxMetricsSource?
                
> Move Master Metrics to metrics 2
> --------------------------------
>
>                 Key: HBASE-6411
>                 URL: https://issues.apache.org/jira/browse/HBASE-6411
>             Project: HBase
>          Issue Type: Sub-task
>            Reporter: Elliott Clark
>            Assignee: Elliott Clark
>         Attachments: HBASE-6411-0.patch, HBASE-6411-1.patch, 
> HBASE-6411-2.patch, HBASE-6411_concept.patch
>
>
> Move Master Metrics to metrics 2

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to