public class IndexMergerV9 extends Object implements IndexMerger
| Modifier and Type | Field and Description |
|---|---|
static ColumnCapabilities.CoercionLogic |
DIMENSION_CAPABILITY_MERGE_LOGIC |
static ColumnCapabilities.CoercionLogic |
METRIC_CAPABILITY_MERGE_LOGIC |
INVALID_ROW, SERIALIZER_UTILS, UNLIMITED_MAX_COLUMNS_TO_MERGE| Constructor and Description |
|---|
IndexMergerV9(com.fasterxml.jackson.databind.ObjectMapper mapper,
IndexIO indexIO,
SegmentWriteOutMediumFactory defaultSegmentWriteOutMediumFactory)
This constructor is used only for Hadoop ingestion and Tranquility as they do not support storing empty columns yet.
|
IndexMergerV9(com.fasterxml.jackson.databind.ObjectMapper mapper,
IndexIO indexIO,
SegmentWriteOutMediumFactory defaultSegmentWriteOutMediumFactory,
boolean storeEmptyColumns) |
| Modifier and Type | Method and Description |
|---|---|
File |
merge(List<IndexableAdapter> indexes,
boolean rollup,
AggregatorFactory[] metricAggs,
File outDir,
DimensionsSpec dimensionsSpec,
IndexSpec indexSpec,
int maxColumnsToMerge)
Only used as a convenience method in tests.
|
File |
mergeQueryableIndex(List<QueryableIndex> indexes,
boolean rollup,
AggregatorFactory[] metricAggs,
DimensionsSpec dimensionsSpec,
File outDir,
IndexSpec indexSpec,
IndexSpec indexSpecForIntermediatePersists,
ProgressIndicator progress,
SegmentWriteOutMediumFactory segmentWriteOutMediumFactory,
int maxColumnsToMerge)
Merge a collection of
QueryableIndex. |
File |
persist(IncrementalIndex index,
org.joda.time.Interval dataInterval,
File outDir,
IndexSpec indexSpec,
ProgressIndicator progress,
SegmentWriteOutMediumFactory segmentWriteOutMediumFactory)
Persist an IncrementalIndex to disk in such a way that it can be loaded back up as a
QueryableIndex. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetLexicographicMergedDimensions, getLongestSharedDimOrder, getMergedDimensions, getMergedDimensionsFromQueryableIndexes, isDimensionOrderingValid, makeRowIteratorWithConvertedDimensionColumns, mergeIndexed, mergeQueryableIndex, persist, persist, toIndexableAdapters, toMergedIndexRowIteratorpublic static final ColumnCapabilities.CoercionLogic DIMENSION_CAPABILITY_MERGE_LOGIC
public static final ColumnCapabilities.CoercionLogic METRIC_CAPABILITY_MERGE_LOGIC
public IndexMergerV9(com.fasterxml.jackson.databind.ObjectMapper mapper,
IndexIO indexIO,
SegmentWriteOutMediumFactory defaultSegmentWriteOutMediumFactory,
boolean storeEmptyColumns)
@Inject
public IndexMergerV9(com.fasterxml.jackson.databind.ObjectMapper mapper,
IndexIO indexIO,
SegmentWriteOutMediumFactory defaultSegmentWriteOutMediumFactory)
HadoopDruidIndexerConfig and PlumberSchool for hadoop ingestion and Tranquility, respectively.public File persist(IncrementalIndex index, org.joda.time.Interval dataInterval, File outDir, IndexSpec indexSpec, ProgressIndicator progress, @Nullable SegmentWriteOutMediumFactory segmentWriteOutMediumFactory) throws IOException
IndexMergerQueryableIndex.
This is *not* thread-safe and havoc will ensue if this is called and writes are still occurring on the
IncrementalIndex object.persist in interface IndexMergerindex - the IncrementalIndex to persistdataInterval - the Interval that the data represents. Typically, this is the same as the
interval from the corresponding SegmentId.outDir - the directory to persist the data toindexSpec - storage and compression optionsprogress - an object that will receive progress updatessegmentWriteOutMediumFactory - controls allocation of temporary data structuresIOException - if an IO error occurs persisting the indexpublic File mergeQueryableIndex(List<QueryableIndex> indexes, boolean rollup, AggregatorFactory[] metricAggs, @Nullable DimensionsSpec dimensionsSpec, File outDir, IndexSpec indexSpec, IndexSpec indexSpecForIntermediatePersists, ProgressIndicator progress, @Nullable SegmentWriteOutMediumFactory segmentWriteOutMediumFactory, int maxColumnsToMerge) throws IOException
IndexMergerQueryableIndex.mergeQueryableIndex in interface IndexMergerIOExceptionpublic File merge(List<IndexableAdapter> indexes, boolean rollup, AggregatorFactory[] metricAggs, File outDir, DimensionsSpec dimensionsSpec, IndexSpec indexSpec, int maxColumnsToMerge) throws IOException
IndexMergerQueryableIndex, use
IndexMerger.mergeQueryableIndex(List, boolean, AggregatorFactory[], DimensionsSpec, File, IndexSpec, IndexSpec, ProgressIndicator, SegmentWriteOutMediumFactory, int).
To merge multiple IncrementalIndex, call one of the IndexMerger.persist(org.apache.druid.segment.incremental.IncrementalIndex, java.io.File, org.apache.druid.segment.IndexSpec, org.apache.druid.segment.writeout.SegmentWriteOutMediumFactory) methods and then merge the resulting
QueryableIndex.merge in interface IndexMergerIOExceptionCopyright © 2011–2022 The Apache Software Foundation. All rights reserved.