Package io.trino.execution
Interface ManagedQueryExecution
-
- All Known Subinterfaces:
DispatchQuery
- All Known Implementing Classes:
FailedDispatchQuery,LocalDispatchQuery
public interface ManagedQueryExecution
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddStateChangeListener(StateMachine.StateChangeListener<QueryState> stateChangeListener)Listener is always notified asynchronously using a dedicated notification thread pool so, care should be taken to avoid leakingthiswhen adding a listener in a constructor.voidfail(Throwable cause)BasicQueryInfogetBasicQueryInfo()Optional<ErrorCode>getErrorCode()QueryInfogetFullQueryInfo()SessiongetSession()QueryStategetState()io.airlift.units.DurationgetTotalCpuTime()io.airlift.units.DataSizegetTotalMemoryReservation()io.airlift.units.DataSizegetUserMemoryReservation()booleanisDone()voidstartWaitingForResources()
-
-
-
Method Detail
-
startWaitingForResources
void startWaitingForResources()
-
fail
void fail(Throwable cause)
-
addStateChangeListener
void addStateChangeListener(StateMachine.StateChangeListener<QueryState> stateChangeListener)
Listener is always notified asynchronously using a dedicated notification thread pool so, care should be taken to avoid leakingthiswhen adding a listener in a constructor. Additionally, it is possible notifications are observed out of order due to the asynchronous execution.
-
getSession
Session getSession()
-
getUserMemoryReservation
io.airlift.units.DataSize getUserMemoryReservation()
-
getTotalMemoryReservation
io.airlift.units.DataSize getTotalMemoryReservation()
-
getTotalCpuTime
io.airlift.units.Duration getTotalCpuTime()
-
getBasicQueryInfo
BasicQueryInfo getBasicQueryInfo()
-
getFullQueryInfo
QueryInfo getFullQueryInfo()
-
getState
QueryState getState()
-
isDone
boolean isDone()
-
-