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

Ashish Singhi commented on HBASE-16910:
---------------------------------------

We faced this issue yesterday in one of our test cluster also which is based on 
branch-1.0.
[~zghaobac], can you provide patch for other branches also. If not let me know 
I can prepare the patches.
Ideally bug fix should go to all the running versions.

> Avoid NPE when starting StochasticLoadBalancer
> ----------------------------------------------
>
>                 Key: HBASE-16910
>                 URL: https://issues.apache.org/jira/browse/HBASE-16910
>             Project: HBase
>          Issue Type: Bug
>          Components: Balancer
>    Affects Versions: 2.0.0
>            Reporter: Guanghao Zhang
>            Assignee: Guanghao Zhang
>            Priority: Minor
>             Fix For: 2.0.0
>
>         Attachments: HBASE-16910-v1.patch, HBASE-16910.patch
>
>
> When master start, it initialize StochasticLoadBalancer.
> {code}
> this.balancer.setClusterStatus(getClusterStatus());
> this.balancer.setMasterServices(this);
> {code}
> It first setClusterStatus(), then setMasterService(). But in setClusterStatus 
> method, it use master service which is not initialized. So it will throw NPE.
> {code}
> int tablesCount = isByTable ? services.getTableDescriptors().getAll().size() 
> : 1;
> {code}
> It happens when set isByTable is ture.



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

Reply via email to