org.apache.hadoop.hbase.master
Class BulkReOpen
java.lang.Object
org.apache.hadoop.hbase.master.BulkAssigner
org.apache.hadoop.hbase.master.BulkReOpen
@InterfaceAudience.Private
public class BulkReOpen
- extends BulkAssigner
Performs bulk reopen of the list of regions provided to it.
Method Summary |
boolean |
bulkReOpen()
|
protected int |
getThreadCount()
Configuration knobs "hbase.bulk.reopen.threadpool.size" number of regions
that can be reopened concurrently. |
protected void |
populatePool(ExecutorService pool)
Unassign all regions, so that they go through the regular region
assignment flow (in assignment manager) and are re-opened. |
protected boolean |
waitUntilDone(long timeout)
Reopen the regions asynchronously, so always returns true immediately. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BulkReOpen
public BulkReOpen(Server server,
Map<ServerName,List<HRegionInfo>> serverToRegions,
AssignmentManager am)
populatePool
protected void populatePool(ExecutorService pool)
- Unassign all regions, so that they go through the regular region
assignment flow (in assignment manager) and are re-opened.
- Specified by:
populatePool
in class BulkAssigner
waitUntilDone
protected boolean waitUntilDone(long timeout)
- Reopen the regions asynchronously, so always returns true immediately.
- Specified by:
waitUntilDone
in class BulkAssigner
- Parameters:
timeout
- How long to wait.
- Returns:
- true
getThreadCount
protected int getThreadCount()
- Configuration knobs "hbase.bulk.reopen.threadpool.size" number of regions
that can be reopened concurrently. The maximum number of threads the master
creates is never more than the number of region servers.
If configuration is not defined it defaults to 20
- Overrides:
getThreadCount
in class BulkAssigner
bulkReOpen
public boolean bulkReOpen()
throws InterruptedException,
IOException
- Throws:
InterruptedException
IOException
Copyright © 2015 The Apache Software Foundation. All rights reserved.