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

ASF GitHub Bot commented on HBASE-28327:
----------------------------------------

eab148 opened a new pull request, #5647:
URL: https://github.com/apache/hbase/pull/5647

   JIRA: https://issues.apache.org/jira/browse/HBASE-28327
   
   This will help us clean up metrics safely. We will remove a `Metric` with 
the specified `name` from the metric registry if and only if the provided 
`metric` matches the object in the registry.
   
   




> Add remove(String key, Metric metric) method to MetricRegistry interface
> ------------------------------------------------------------------------
>
>                 Key: HBASE-28327
>                 URL: https://issues.apache.org/jira/browse/HBASE-28327
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Evelyn Boland
>            Priority: Major
>
> Add a `remove(String name, Metric metric)` method to the `MetricRegistry` 
> interface. Right now the interface only contains a `remove(String name)` 
> method.
> This additional remove method will give users the power to remove a `Metric` 
> with the specified `name` from the metric registry if and only if the 
> provided `metric` matches the object in the registry.
> Implementing the new `remove(String metric, Metric metric)` should be 
> straight forward because the `MetricRegistryImpl` class stores metrics in a 
> `ConcurrentMap`, which already contains a `remove(Object key, Object value)` 
> method
> This change will not be a breaking one because the interface is marked with 
> `@IntefaceStability.Evolving`
> [~rmdmattingly]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to