@InterfaceAudience.Private public class RedundantKVGenerator extends Object
Constructor and Description |
---|
RedundantKVGenerator()
Default constructor, assumes all parameters from class constants.
|
RedundantKVGenerator(Random randomizer,
int numberOfRowPrefixes,
int averagePrefixLength,
int prefixLengthVariance,
int averageSuffixLength,
int suffixLengthVariance,
int numberOfRows,
float chanceForSameQualifier,
float chanceForSimiliarQualifier,
int averageQualifierLength,
int qualifierLengthVariance,
int columnFamilyLength,
int valueLength,
float chanceForZeroValue,
int baseTimestampDivide,
int timestampDiffSize)
Various configuration options for generating key values
|
public RedundantKVGenerator()
public RedundantKVGenerator(Random randomizer, int numberOfRowPrefixes, int averagePrefixLength, int prefixLengthVariance, int averageSuffixLength, int suffixLengthVariance, int numberOfRows, float chanceForSameQualifier, float chanceForSimiliarQualifier, int averageQualifierLength, int qualifierLengthVariance, int columnFamilyLength, int valueLength, float chanceForZeroValue, int baseTimestampDivide, int timestampDiffSize)
randomizer
- pick things by randompublic List<KeyValue> generateTestKeyValues(int howMany)
howMany
- How many Key values should be generated.public List<KeyValue> generateTestKeyValues(int howMany, boolean useTags)
howMany
- How many Key values should be generated.public static ByteBuffer convertKvToByteBuffer(List<KeyValue> keyValues, boolean includesMemstoreTS)
keyValues
- list of KeyValues to be converted.public RedundantKVGenerator setCommonPrefix(byte[] prefix)
public RedundantKVGenerator setRandomizer(Random randomizer)
public RedundantKVGenerator setNumberOfRowPrefixes(int numberOfRowPrefixes)
public RedundantKVGenerator setAveragePrefixLength(int averagePrefixLength)
public RedundantKVGenerator setPrefixLengthVariance(int prefixLengthVariance)
public RedundantKVGenerator setAverageSuffixLength(int averageSuffixLength)
public RedundantKVGenerator setSuffixLengthVariance(int suffixLengthVariance)
public RedundantKVGenerator setNumberOfRows(int numberOfRows)
public RedundantKVGenerator setChanceForSameQualifier(float chanceForSameQualifier)
public RedundantKVGenerator setChanceForSimilarQualifier(float chanceForSimiliarQualifier)
public RedundantKVGenerator setAverageQualifierLength(int averageQualifierLength)
public RedundantKVGenerator setQualifierLengthVariance(int qualifierLengthVariance)
public RedundantKVGenerator setColumnFamilyLength(int columnFamilyLength)
public RedundantKVGenerator setFamily(byte[] family)
public RedundantKVGenerator setValueLength(int valueLength)
public RedundantKVGenerator setChanceForZeroValue(float chanceForZeroValue)
public RedundantKVGenerator setBaseTimestampDivide(int baseTimestampDivide)
public RedundantKVGenerator setTimestampDiffSize(int timestampDiffSize)
Copyright © 2007-2016 The Apache Software Foundation. All Rights Reserved.