mwkang commented on issue #1193: HBASE-23561 Look up of Region in Master by 
encoded region name is O(n)
URL: https://github.com/apache/hbase/pull/1193#issuecomment-590070993
 
 
   I think the current code may have different values for the two maps.
   What do you think about changing it like below?
   
   ```java
   RegionStateNode node = 
regionsMap.computeIfAbsent(regionInfo.getRegionName(),key -> new 
RegionStateNode(regionInfo, regionInTransition));
   encodedRegionsMap.putIfAbsent(node.getRegionInfo().getEncodedName(), node);
   return node;
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to