Package org.apache.hadoop.hbase.io.hfile
Class TestHFileWriterV3WithDataEncoders
java.lang.Object
org.apache.hadoop.hbase.io.hfile.TestHFileWriterV3WithDataEncoders
Testing writing a version 3
HFile
for all encoded blocks-
Field Summary
Modifier and TypeFieldDescriptionstatic final HBaseClassTestRule
private org.apache.hadoop.conf.Configuration
private org.apache.hadoop.hbase.io.encoding.DataBlockEncoding
private org.apache.hadoop.fs.FileSystem
private static final org.slf4j.Logger
private static final Random
private static final HBaseTestingUtility
private boolean
-
Constructor Summary
ConstructorDescriptionTestHFileWriterV3WithDataEncoders
(boolean useTags, org.apache.hadoop.hbase.io.encoding.DataBlockEncoding dataBlockEncoding) -
Method Summary
Modifier and TypeMethodDescriptionstatic Collection<Object[]>
private long
scanBlocks
(int entryCount, org.apache.hadoop.hbase.io.hfile.HFileContext context, List<org.apache.hadoop.hbase.KeyValue> keyValues, org.apache.hadoop.fs.FSDataInputStream fsdis, org.apache.hadoop.hbase.io.hfile.FixedFileTrailer trailer, org.apache.hadoop.hbase.io.hfile.HFileContext meta, org.apache.hadoop.hbase.io.hfile.HFileBlock.FSReader blockReader, int entriesRead, int blocksRead, org.apache.hadoop.hbase.io.encoding.DataBlockEncoder encoder) void
setUp()
void
private void
testHFileFormatV3Internals
(boolean useTags) void
private void
testMidKeyInHFileInternals
(boolean useTags) private void
writeDataAndReadFromHFile
(org.apache.hadoop.fs.Path hfilePath, org.apache.hadoop.hbase.io.compress.Compression.Algorithm compressAlgo, int entryCount, boolean findMidKey, boolean useTags) private void
writeKeyValues
(int entryCount, boolean useTags, org.apache.hadoop.hbase.io.hfile.HFile.Writer writer, Random rand, List<org.apache.hadoop.hbase.KeyValue> keyValues)
-
Field Details
-
CLASS_RULE
-
LOG
-
TEST_UTIL
-
RNG
-
conf
-
fs
-
useTags
-
dataBlockEncoding
-
-
Constructor Details
-
TestHFileWriterV3WithDataEncoders
public TestHFileWriterV3WithDataEncoders(boolean useTags, org.apache.hadoop.hbase.io.encoding.DataBlockEncoding dataBlockEncoding)
-
-
Method Details
-
parameters
-
setUp
- Throws:
IOException
-
testHFileFormatV3
- Throws:
IOException
-
testHFileFormatV3Internals
- Throws:
IOException
-
testMidKeyInHFile
- Throws:
IOException
-
testMidKeyInHFileInternals
- Throws:
IOException
-
writeDataAndReadFromHFile
private void writeDataAndReadFromHFile(org.apache.hadoop.fs.Path hfilePath, org.apache.hadoop.hbase.io.compress.Compression.Algorithm compressAlgo, int entryCount, boolean findMidKey, boolean useTags) throws IOException - Throws:
IOException
-
scanBlocks
private long scanBlocks(int entryCount, org.apache.hadoop.hbase.io.hfile.HFileContext context, List<org.apache.hadoop.hbase.KeyValue> keyValues, org.apache.hadoop.fs.FSDataInputStream fsdis, org.apache.hadoop.hbase.io.hfile.FixedFileTrailer trailer, org.apache.hadoop.hbase.io.hfile.HFileContext meta, org.apache.hadoop.hbase.io.hfile.HFileBlock.FSReader blockReader, int entriesRead, int blocksRead, org.apache.hadoop.hbase.io.encoding.DataBlockEncoder encoder) throws IOException - Throws:
IOException
-
writeKeyValues
private void writeKeyValues(int entryCount, boolean useTags, org.apache.hadoop.hbase.io.hfile.HFile.Writer writer, Random rand, List<org.apache.hadoop.hbase.KeyValue> keyValues) throws IOException - Throws:
IOException
-