@InterfaceAudience.Public public class RegionMover extends AbstractHBaseTool implements Closeable
load() or unload() methods for the desired operations.| Modifier and Type | Class and Description |
|---|---|
static class |
RegionMover.RegionMoverBuilder
Builder for Region mover.
|
AbstractHBaseTool.OptionsOrderComparator| Modifier and Type | Field and Description |
|---|---|
static int |
DEFAULT_MOVE_RETRIES_MAX |
static int |
DEFAULT_MOVE_WAIT_MAX |
static int |
DEFAULT_SERVERSTART_WAIT_MAX |
static String |
MOVE_RETRIES_MAX_KEY |
static String |
MOVE_WAIT_MAX_KEY |
static String |
SERVERSTART_WAIT_MAX_KEY |
cmdLineArgs, conf, EXIT_FAILURE, EXIT_SUCCESS, LONG_HELP_OPTION, options, SHORT_HELP_OPTION| Modifier and Type | Method and Description |
|---|---|
protected void |
addOptions() |
void |
close() |
protected int |
doWork() |
boolean |
load()
Loads the specified
hostname with regions listed in the filename RegionMover
Object has to be created using RegionMover(RegionMoverBuilder) |
static void |
main(String[] args) |
protected void |
processOptions(org.apache.hbase.thirdparty.org.apache.commons.cli.CommandLine cmd) |
boolean |
unload()
Unload regions from given
hostname using ack/noAck mode and maxthreads.In
noAck mode we do not make sure that region is successfully online on the target region
server,hence it is best effort.We do not unload regions to hostnames given in
excludeFile. |
boolean |
unloadFromRack()
Unload regions from given
hostname using ack/noAck mode and maxthreads.In
noAck mode we do not make sure that region is successfully online on the target region
server,hence it is best effort.We do not unload regions to hostnames given in
excludeFile. |
addOption, addOptNoArg, addOptNoArg, addOptWithArg, addOptWithArg, addRequiredOption, addRequiredOptWithArg, addRequiredOptWithArg, doStaticMain, getConf, getOptionAsDouble, getOptionAsInt, getOptionAsInt, getOptionAsLong, getOptionAsLong, newParser, parseArgs, parseInt, parseLong, printUsage, printUsage, processOldArgs, run, setConfpublic static final String MOVE_RETRIES_MAX_KEY
public static final String MOVE_WAIT_MAX_KEY
public static final String SERVERSTART_WAIT_MAX_KEY
public static final int DEFAULT_MOVE_RETRIES_MAX
public static final int DEFAULT_MOVE_WAIT_MAX
public static final int DEFAULT_SERVERSTART_WAIT_MAX
public void close()
close in interface Closeableclose in interface AutoCloseablepublic boolean load()
throws ExecutionException,
InterruptedException,
TimeoutException
hostname with regions listed in the filename RegionMover
Object has to be created using RegionMover(RegionMoverBuilder)ExecutionExceptionInterruptedExceptionTimeoutExceptionpublic boolean unload()
throws InterruptedException,
ExecutionException,
TimeoutException
hostname using ack/noAck mode and maxthreads.In
noAck mode we do not make sure that region is successfully online on the target region
server,hence it is best effort.We do not unload regions to hostnames given in
excludeFile. If designatedFile is present with some contents, we will unload regions
to hostnames provided in designatedFileInterruptedExceptionExecutionExceptionTimeoutExceptionpublic boolean unloadFromRack()
throws InterruptedException,
ExecutionException,
TimeoutException
hostname using ack/noAck mode and maxthreads.In
noAck mode we do not make sure that region is successfully online on the target region
server,hence it is best effort.We do not unload regions to hostnames given in
excludeFile. If designatedFile is present with some contents, we will unload regions
to hostnames provided in designatedFile. While unloading regions, destination
RegionServers are selected from different rack i.e regions should not move to any RegionServers
that belong to same rack as source RegionServer.InterruptedExceptionExecutionExceptionTimeoutExceptionprotected void addOptions()
addOptions in class AbstractHBaseToolprotected void processOptions(org.apache.hbase.thirdparty.org.apache.commons.cli.CommandLine cmd)
processOptions in class AbstractHBaseToolprotected int doWork()
throws Exception
doWork in class AbstractHBaseToolExceptionpublic static void main(String[] args)
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.