Package org.apache.druid.indexer.path
Class MetadataStoreBasedUsedSegmentsRetriever
- java.lang.Object
-
- org.apache.druid.indexer.path.MetadataStoreBasedUsedSegmentsRetriever
-
- All Implemented Interfaces:
UsedSegmentsRetriever
public class MetadataStoreBasedUsedSegmentsRetriever extends Object implements UsedSegmentsRetriever
-
-
Constructor Summary
Constructors Constructor Description MetadataStoreBasedUsedSegmentsRetriever(org.apache.druid.indexing.overlord.IndexerMetadataStorageCoordinator indexerMetadataStorageCoordinator)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Collection<org.apache.druid.timeline.DataSegment>retrieveUsedSegmentsForIntervals(String dataSource, List<org.joda.time.Interval> intervals, org.apache.druid.indexing.overlord.Segments visibility)Retrieve (potentially, from a remote node) all segments which may include any data in the interval and are marked as used.
-
-
-
Method Detail
-
retrieveUsedSegmentsForIntervals
public Collection<org.apache.druid.timeline.DataSegment> retrieveUsedSegmentsForIntervals(String dataSource, List<org.joda.time.Interval> intervals, org.apache.druid.indexing.overlord.Segments visibility)
Description copied from interface:UsedSegmentsRetrieverRetrieve (potentially, from a remote node) all segments which may include any data in the interval and are marked as used. The order of segments within the returned collection is unspecified, but each segment is guaranteed to appear in the collection only once.- Specified by:
retrieveUsedSegmentsForIntervalsin interfaceUsedSegmentsRetriever- Parameters:
dataSource- The datasource to queryintervals- The intervals for which used segments are to be returnedvisibility- Whether only visible or visible as well as overshadowed segments should be returned. The visibility is considered within the specified intervals: that is, a segment which is visible outside of the specified intervals, but overshadowed on the specified intervals will not be returned ifSegments.ONLY_VISIBLEis passed. See more precise description in the doc forSegments.- Returns:
- The DataSegments which include data in the requested intervals. These segments may contain data outside the requested interval.
-
-