hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ted Yu (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (HBASE-10704) BaseLoadBalancer#roundRobinAssignment() may add same region to assignment plan multiple times
Date Mon, 10 Mar 2014 22:57:45 GMT

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

Ted Yu updated HBASE-10704:
---------------------------

    Attachment: 10704-v2.txt

The cause for duplicate entries was that region deemed to lower availability would be inserted
more than once by the following loop:
{code}
      for (int j = 0; j < numServers; j++) { // try all servers one by one
{code}
Patch v2 provides a simpler fix.

Looks like the above loop is not needed.

> BaseLoadBalancer#roundRobinAssignment() may add same region to assignment plan multiple
times
> ---------------------------------------------------------------------------------------------
>
>                 Key: HBASE-10704
>                 URL: https://issues.apache.org/jira/browse/HBASE-10704
>             Project: HBase
>          Issue Type: Sub-task
>            Reporter: Ted Yu
>            Assignee: Ted Yu
>         Attachments: 10704-v1.txt, 10704-v2.txt
>
>
> I noticed the following exception in some unit tests:
> {code}
> 2014-03-09 03:38:13,523 WARN  [s111-s2.cs1cloud.internal,57347,1394350359795-GeneralBulkAssigner-2]
master.GeneralBulkAssigner$SingleServerBulkAssigner(232): Failed bulking assigning 18 region(s)
to s111.internal,46094,1394350360588, and continue to bulk assign others
> java.lang.NullPointerException
> 	at org.apache.hadoop.hbase.master.AssignmentManager.assign(AssignmentManager.java:1505)
> 	at org.apache.hadoop.hbase.master.GeneralBulkAssigner$SingleServerBulkAssigner.run(GeneralBulkAssigner.java:228)
> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
> 	at java.lang.Thread.run(Thread.java:722)
> {code}
> Here is related code:
> {code}
>           Lock lock = locks.remove(encodedName);
>           lock.unlock();
> {code}
> lock was null due to BaseLoadBalancer#roundRobinAssignment() adding same region to assignment
plan multiple times.
> This happens in computing lastFewRegions where cluster.wouldLowerAvailability() returns
true.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message