[ https://issues.apache.org/jira/browse/HBASE-5088?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13175887#comment-13175887 ]
Jieshan Bean commented on HBASE-5088: ------------------------------------- @Ted, At first, I also thought we would get a higher performance with this patch, because all the keywords of "synchronized" removed. But it slowdown. I agree with the explaination from Lars. Our JDK version is 1.6.0_22. And the below is our OS information: {noformat} C3S3:~ # cat /proc/version Linux version 2.6.32.12-0.7-default (geeko@buildhost) (gcc version 4.3.4 [gcc-4_ 3-branch revision 152973] (SUSE Linux) ) #1 SMP 2010-05-20 11:14:20 +0200 C3S3:/proc # lsb_release -a LSB Version: core-2.0-noarch:core-3.2-noarch:core-4.0-noarch:core-2.0-x86_64:core-3.2-x86_64:core-4.0-x86_64:desktop-4.0-amd64:desktop-4.0-noarch:graphics-2.0-amd64:graphics-2.0-noarch:graphics-3.2-amd64:graphics-3.2-noarch:graphics-4.0-amd64:graphics-4.0-noarch Distributor ID: SUSE LINUX Description: SUSE Linux Enterprise Server 11 (x86_64) Release: 11 Codename: n/a {noformat} We'll take more tests accross the read vs write and give out the results. @Lars, Sorry, I didn't do another comparison with SoftvalueSortedMap replaced by ConcurrentSkiplistMap.And am planning to do it. Including the functional test and the performance test. And then, we can choose a better one. > A concurrency issue on SoftValueSortedMap > ----------------------------------------- > > Key: HBASE-5088 > URL: https://issues.apache.org/jira/browse/HBASE-5088 > Project: HBase > Issue Type: Bug > Components: client > Affects Versions: 0.90.4, 0.94.0 > Reporter: Jieshan Bean > Assignee: Jieshan Bean > Attachments: 5088-useMapInterfaces.txt, 5088.generics.txt, > HBase-5088-90.patch, HBase-5088-trunk.patch, HBase5088Reproduce.java > > > SoftValueSortedMap is backed by a TreeMap. All the methods in this class are > synchronized. If we use this method to add/delete elements, it's ok. > But in HConnectionManager#getCachedLocation, it use headMap to get a view > from SoftValueSortedMap#internalMap. Once we operate > on this view map(like add/delete) in other threads, a concurrency issue may > occur. -- 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