Package org.apache.hadoop.hbase.util
Class MultiThreadedUpdater
java.lang.Object
org.apache.hadoop.hbase.util.MultiThreadedAction
org.apache.hadoop.hbase.util.MultiThreadedWriterBase
org.apache.hadoop.hbase.util.MultiThreadedUpdater
- Direct Known Subclasses:
IntegrationTestRegionReplicaReplication.DelayingMultiThreadedUpdater
,MultiThreadedUpdaterWithACL
Creates multiple threads that write key/values into the
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.hadoop.hbase.util.MultiThreadedAction
MultiThreadedAction.DefaultDataGenerator
-
Field Summary
Modifier and TypeFieldDescriptionprivate boolean
private boolean
private static final org.slf4j.Logger
private final double
protected Set<MultiThreadedUpdater.HBaseUpdaterThread>
private MultiThreadedWriterBase
Fields inherited from class org.apache.hadoop.hbase.util.MultiThreadedWriterBase
failedKeySet, nextKeyToWrite, trackWroteKeys, wroteKeyQueueSize, wroteKeys, wroteUpToKey
Fields inherited from class org.apache.hadoop.hbase.util.MultiThreadedAction
conf, connection, dataGenerator, endKey, numCols, numKeys, numThreads, numThreadsWorking, REPORTING_INTERVAL_MS, startKey, tableName, totalOpTimeMs, verbose
-
Constructor Summary
ConstructorDescriptionMultiThreadedUpdater
(LoadTestDataGenerator dataGen, org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.hbase.TableName tableName, double updatePercent) -
Method Summary
Modifier and TypeMethodDescriptionprotected void
addUpdaterThreads
(int numThreads) private long
void
linkToWriter
(MultiThreadedWriterBase writer) void
mutate
(org.apache.hadoop.hbase.client.Table table, org.apache.hadoop.hbase.client.Mutation m, long keyBase) void
mutate
(org.apache.hadoop.hbase.client.Table table, org.apache.hadoop.hbase.client.Mutation m, long keyBase, byte[] row, byte[] cf, byte[] q, byte[] v) void
setBatchUpdate
(boolean isBatchUpdate) Use batch vs.void
setIgnoreNonceConflicts
(boolean value) void
start
(long startKey, long endKey, int numThreads) void
Methods inherited from class org.apache.hadoop.hbase.util.MultiThreadedWriterBase
createWriteKeysQueue, failedToWriteKey, getNumWriteFailures, getRegionDebugInfoSafe, progressInfo, setTrackWroteKeys, wroteUpToKey
Methods inherited from class org.apache.hadoop.hbase.util.MultiThreadedAction
appendToStatus, appendToStatus, close, getEndKey, isDone, startThreads, verifyResultAgainstDataGenerator, verifyResultAgainstDataGenerator
-
Field Details
-
LOG
-
updaters
-
writer
-
isBatchUpdate
-
ignoreNonceConflicts
-
updatePercent
-
-
Constructor Details
-
MultiThreadedUpdater
public MultiThreadedUpdater(LoadTestDataGenerator dataGen, org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.hbase.TableName tableName, double updatePercent) throws IOException - Throws:
IOException
-
-
Method Details
-
setBatchUpdate
Use batch vs. separate updates for every column in a row -
linkToWriter
-
start
- Overrides:
start
in classMultiThreadedWriterBase
- Throws:
IOException
-
addUpdaterThreads
- Throws:
IOException
-
getNextKeyToUpdate
-
waitForFinish
- Overrides:
waitForFinish
in classMultiThreadedAction
-
mutate
public void mutate(org.apache.hadoop.hbase.client.Table table, org.apache.hadoop.hbase.client.Mutation m, long keyBase) -
mutate
public void mutate(org.apache.hadoop.hbase.client.Table table, org.apache.hadoop.hbase.client.Mutation m, long keyBase, byte[] row, byte[] cf, byte[] q, byte[] v) -
setIgnoreNonceConflicts
-