public class DictionaryToRawIndexConverter extends Object
| Constructor and Description |
|---|
DictionaryToRawIndexConverter() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
convert()
Method to perform the conversion for a set of segments in the
_dataDir |
boolean |
convertSegment(File segmentDir,
String[] columns,
File outputDir,
boolean compressOutput)
This method converts the specified columns of the given segment from dictionary encoded
forward index to raw index without dictionary.
|
static void |
main(String[] args)
Main method for the class.
|
DictionaryToRawIndexConverter |
setColumns(String columns)
Setter for columns to convert.
|
DictionaryToRawIndexConverter |
setDataDir(String dataDir)
Setter for
_dataDir |
DictionaryToRawIndexConverter |
setOutputDir(String outputDir)
Setter for
_outputDir |
DictionaryToRawIndexConverter |
setOverwrite(boolean overwrite)
Setter for
_overwrite
When set to true, already existing output directory is overwritten. |
public DictionaryToRawIndexConverter setDataDir(String dataDir)
_dataDirdataDir - Data directory containing un-tarred segments.public DictionaryToRawIndexConverter setOutputDir(String outputDir)
_outputDiroutputDir - Directory where output segments should be writtenpublic DictionaryToRawIndexConverter setColumns(String columns)
columns - Comma separated list of columnspublic DictionaryToRawIndexConverter setOverwrite(boolean overwrite)
_overwrite
When set to true, already existing output directory is overwritten.overwrite - True for overwriting existing output dir, False otherwisepublic boolean convert()
throws Exception
_dataDirExceptionpublic boolean convertSegment(File segmentDir, String[] columns, File outputDir, boolean compressOutput) throws Exception
segmentDir - Segment directorycolumns - Columns to convertoutputDir - Directory for writing output segmentcompressOutput - Tar/gzip the output segmentExceptionCopyright © 2018–2020 Apache Software Foundation. All rights reserved.