Class DriverTask
- java.lang.Object
-
- org.apache.iotdb.db.mpp.execution.schedule.task.DriverTask
-
- All Implemented Interfaces:
IDIndexedAccessible
public class DriverTask extends java.lang.Object implements IDIndexedAccessible
the scheduling element ofDriverTaskThread. It wraps a single Driver.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classDriverTask.SchedulePriorityComparatora comparator of ddl, the higher the schedulePriority is, the low order it has.static classDriverTask.TimeoutComparatora comparator of ddl, the less the ddl is, the low order it has.
-
Constructor Summary
Constructors Constructor Description DriverTask()Initialize a dummy instance for queryHolderDriverTask(IDriver instance, long timeoutMs, DriverTaskStatus status)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object o)java.lang.StringgetAbortCause()longgetDDL()IDrivergetFragmentInstance()DriverTaskIDgetId()doublegetSchedulePriority()DriverTaskStatusgetStatus()inthashCode()booleanisEndState()voidlock()voidsetAbortCause(java.lang.String abortCause)voidsetId(ID id)voidsetStatus(DriverTaskStatus status)voidunlock()voidupdateSchedulePriority(ExecutionContext context)Update the schedule priority according to the execution context.
-
-
-
Constructor Detail
-
DriverTask
public DriverTask()
Initialize a dummy instance for queryHolder
-
DriverTask
public DriverTask(IDriver instance, long timeoutMs, DriverTaskStatus status)
-
-
Method Detail
-
getId
public DriverTaskID getId()
- Specified by:
getIdin interfaceIDIndexedAccessible
-
setId
public void setId(ID id)
- Specified by:
setIdin interfaceIDIndexedAccessible
-
getStatus
public DriverTaskStatus getStatus()
-
isEndState
public boolean isEndState()
-
getFragmentInstance
public IDriver getFragmentInstance()
-
setStatus
public void setStatus(DriverTaskStatus status)
-
updateSchedulePriority
public void updateSchedulePriority(ExecutionContext context)
Update the schedule priority according to the execution context.- Parameters:
context- the last execution context.
-
lock
public void lock()
-
unlock
public void unlock()
-
getSchedulePriority
public double getSchedulePriority()
-
getDDL
public long getDDL()
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
getAbortCause
public java.lang.String getAbortCause()
-
setAbortCause
public void setAbortCause(java.lang.String abortCause)
-
-