public abstract class MergeTaskBase extends AbstractFixedIntervalTask
| Modifier | Constructor and Description |
|---|---|
protected |
MergeTaskBase(String id,
String dataSource,
List<DataSegment> segments,
SegmentWriteOutMediumFactory segmentWriteOutMediumFactory,
Map<String,Object> context) |
| Modifier and Type | Method and Description |
|---|---|
int |
getPriority()
Returns task priority.
|
List<DataSegment> |
getSegments() |
SegmentWriteOutMediumFactory |
getSegmentWriteOutMediumFactory() |
boolean |
isReady(TaskActionClient taskActionClient)
Checks pre-existing segments in "context" to confirm that this merge query is valid.
|
protected abstract File |
merge(TaskToolbox taskToolbox,
Map<DataSegment,File> segments,
File outDir) |
TaskStatus |
run(TaskToolbox toolbox)
Execute a task.
|
String |
toString() |
protected void |
verifyInputSegments(List<DataSegment> segments) |
getIntervalcanRestore, equals, getClasspathPrefix, getContext, getDataSource, getGroupId, getId, getNodeType, getQueryRunner, getTaskResource, hashCode, stopGracefully, successclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetContextValue, getContextValue, getTypeprotected MergeTaskBase(String id, String dataSource, List<DataSegment> segments, @Nullable SegmentWriteOutMediumFactory segmentWriteOutMediumFactory, Map<String,Object> context)
protected void verifyInputSegments(List<DataSegment> segments)
public int getPriority()
Taskfor default task prioritiespublic TaskStatus run(TaskToolbox toolbox) throws Exception
Tasktoolbox - Toolbox for this taskException - if this task failedpublic boolean isReady(TaskActionClient taskActionClient) throws Exception
isReady in interface TaskisReady in class AbstractFixedIntervalTasktaskActionClient - action client for this task (not the full toolbox)Exception - if the task should be considered a failureprotected abstract File merge(TaskToolbox taskToolbox, Map<DataSegment,File> segments, File outDir) throws Exception
Exceptionpublic List<DataSegment> getSegments()
@Nullable public SegmentWriteOutMediumFactory getSegmentWriteOutMediumFactory()
public String toString()
toString in class AbstractTaskCopyright © 2011–2018. All rights reserved.