HBASE-8451 MetricsMBeanBase has concurrency issues in init (Liang Xie)

git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1476713 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Zhihong Yu 2013-04-28 03:12:19 +00:00
parent 4e28bd8bab
commit e12e470d5f
1 changed files with 3 additions and 3 deletions

View File

@ -19,9 +19,9 @@
package org.apache.hadoop.hbase.metrics;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;
import javax.management.AttributeNotFoundException;
import javax.management.MBeanAttributeInfo;
@ -58,7 +58,7 @@ public class MetricsMBeanBase extends MetricsDynamicMBeanBase {
* not understand
*/
protected Map<String, MetricsBase> extendedAttributes =
new HashMap<String,MetricsBase>();
new ConcurrentHashMap<String, MetricsBase>();
protected MBeanInfo extendedInfo;
protected MetricsMBeanBase( MetricsRegistry mr, String description ) {