hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-16275) Change ServerManager#onlineServers from ConcurrentHashMap to ConcurrentSkipListMap
Date Tue, 02 Aug 2016 17:22:21 GMT

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

Hudson commented on HBASE-16275:
--------------------------------

FAILURE: Integrated in HBase-0.98-on-Hadoop-1.1 #1251 (See [https://builds.apache.org/job/HBase-0.98-on-Hadoop-1.1/1251/])
HBASE-16275 Change ServerManager#onlineServers from ConcurrentHashMap to (apurtell: rev 903e7d5f7a71055636b9ff8a8b48038659de7572)
* hbase-server/src/main/java/org/apache/hadoop/hbase/master/ServerManager.java


> Change ServerManager#onlineServers from ConcurrentHashMap to ConcurrentSkipListMap
> ----------------------------------------------------------------------------------
>
>                 Key: HBASE-16275
>                 URL: https://issues.apache.org/jira/browse/HBASE-16275
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: huaxiang sun
>            Assignee: huaxiang sun
>            Priority: Minor
>             Fix For: 2.0.0, 1.4.0, 0.98.21
>
>         Attachments: HBASE-16275-v001.patch, HBASE-16275-v002.patch, TestServerManagerPerf.java
>
>
> In Class ServerManager, onlineServers is declared as ConcurrentHashMap. In findServerWithSameHostnamePortWithLock(),
it has to do a loop to find if there is a ServerName with same host:port pair. If replaced
with ConcurrentSkipListMap, findServerWithSameHostnamePortWithLock() can be replaced with
a O(logN) implementation. 
> I run some performance comparison(test the function only), it seems that there is no
difference if there are 1000 servers. With more servers, ConcurrentSkipListMap implementation
is going to win big.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message