Class FlushingPlumber
- java.lang.Object
-
- org.apache.druid.segment.realtime.plumber.RealtimePlumber
-
- org.apache.druid.segment.realtime.plumber.FlushingPlumber
-
- All Implemented Interfaces:
Plumber
public class FlushingPlumber extends RealtimePlumber
-
-
Field Summary
-
Fields inherited from interface org.apache.druid.segment.realtime.plumber.Plumber
DUPLICATE, NOT_WRITABLE, THROWAWAY
-
-
Constructor Summary
Constructors Constructor Description FlushingPlumber(org.joda.time.Duration flushDuration, DataSchema schema, RealtimeTuningConfig config, FireDepartmentMetrics metrics, org.apache.druid.java.util.emitter.service.ServiceEmitter emitter, org.apache.druid.query.QueryRunnerFactoryConglomerate conglomerate, DataSegmentAnnouncer segmentAnnouncer, org.apache.druid.query.QueryProcessingPool queryProcessingPool, org.apache.druid.segment.join.JoinableFactory joinableFactory, org.apache.druid.segment.IndexMerger indexMerger, org.apache.druid.segment.IndexIO indexIO, Cache cache, CacheConfig cacheConfig, CachePopulatorStats cachePopulatorStats, com.fasterxml.jackson.databind.ObjectMapper objectMapper)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidfinishJob()Perform any final processing and clean up after ourselves.protected voidflushAfterDuration(long truncatedTime, Sink sink)ObjectstartJob()Perform any initial setup.-
Methods inherited from class org.apache.druid.segment.realtime.plumber.RealtimePlumber
abandonSegment, add, bootstrapSinksFromDisk, computeBaseDir, computeCorruptedFileDumpDir, computePersistDir, getConfig, getQueryRunner, getRejectionPolicy, getSchema, getSinks, initializeExecutors, persist, persistHydrant, shutdownExecutors, startPersistThread
-
-
-
-
Constructor Detail
-
FlushingPlumber
public FlushingPlumber(org.joda.time.Duration flushDuration, DataSchema schema, RealtimeTuningConfig config, FireDepartmentMetrics metrics, org.apache.druid.java.util.emitter.service.ServiceEmitter emitter, org.apache.druid.query.QueryRunnerFactoryConglomerate conglomerate, DataSegmentAnnouncer segmentAnnouncer, org.apache.druid.query.QueryProcessingPool queryProcessingPool, org.apache.druid.segment.join.JoinableFactory joinableFactory, org.apache.druid.segment.IndexMerger indexMerger, org.apache.druid.segment.IndexIO indexIO, Cache cache, CacheConfig cacheConfig, CachePopulatorStats cachePopulatorStats, com.fasterxml.jackson.databind.ObjectMapper objectMapper)
-
-
Method Detail
-
startJob
public Object startJob()
Description copied from interface:PlumberPerform any initial setup. Should be called before using any other methods, and should be paired with a corresponding call toPlumber.finishJob().- Specified by:
startJobin interfacePlumber- Overrides:
startJobin classRealtimePlumber- Returns:
- the metadata of the "newest" segment that might have previously been persisted
-
flushAfterDuration
protected void flushAfterDuration(long truncatedTime, Sink sink)
-
finishJob
public void finishJob()
Description copied from interface:PlumberPerform any final processing and clean up after ourselves. Should be called after all data has been fed into sinks and persisted.- Specified by:
finishJobin interfacePlumber- Overrides:
finishJobin classRealtimePlumber
-
-