[ 
https://issues.apache.org/jira/browse/HBASE-28146?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Duo Zhang resolved HBASE-28146.
-------------------------------
    Fix Version/s: 2.6.0
                   2.4.18
                   2.5.7
     Hadoop Flags: Reviewed
       Resolution: Fixed

Pushed to all 2.x branches.

Thanks [~rmdmattingly] for contributing and [~bbeaudreault] for reviewing!

> ServerManager's rsAdmins map should be thread safe
> --------------------------------------------------
>
>                 Key: HBASE-28146
>                 URL: https://issues.apache.org/jira/browse/HBASE-28146
>             Project: HBase
>          Issue Type: Bug
>    Affects Versions: 2.5.5
>            Reporter: Ray Mattingly
>            Assignee: Ray Mattingly
>            Priority: Major
>             Fix For: 2.6.0, 2.4.18, 2.5.7
>
>
> On 2.x [the ServerManager registers admins in a 
> HashMap|https://github.com/apache/hbase/blob/branch-2/hbase-server/src/main/java/org/apache/hadoop/hbase/master/ServerManager.java].
>  This can result in thread safety issues — we recently observed an exception 
> which caused a region to be indefinitely stuck in transition until we could 
> manually intervene. We saw the following exception in the HMaster logs:
> {code:java}
> 2023-10-11 02:20:05.213 [RSProcedureDispatcher-pool-325] ERROR 
> org.apache.hadoop.hbase.master.procedure.RSProcedureDispatcher: Unexpected 
> error caught, this may cause the procedure to hang forever
>     java.lang.ClassCastException: class java.util.HashMap$Node cannot be cast 
> to class java.util.HashMap$TreeNode (java.util.HashMap$Node and 
> java.util.HashMap$TreeNode are in module java.base of loader 'bootstrap')
>         at java.util.HashMap$TreeNode.moveRootToFront(HashMap.java:1900) 
> ~[?:?]
>         at java.util.HashMap$TreeNode.treeify(HashMap.java:2016) ~[?:?]
>         at java.util.HashMap.treeifyBin(HashMap.java:768) ~[?:?]
>         at java.util.HashMap.putVal(HashMap.java:640) ~[?:?]
>         at java.util.HashMap.put(HashMap.java:608) ~[?:?]
>         at 
> org.apache.hadoop.hbase.master.ServerManager.getRsAdmin(ServerManager.java:723){code}



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

Reply via email to