Package io.prestosql.execution
Class QueryTracker<T extends QueryTracker.TrackedQuery>
- java.lang.Object
-
- io.prestosql.execution.QueryTracker<T>
-
@ThreadSafe public class QueryTracker<T extends QueryTracker.TrackedQuery> extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
QueryTracker.TrackedQuery
-
Constructor Summary
Constructors Constructor Description QueryTracker(QueryManagerConfig queryManagerConfig, ScheduledExecutorService queryManagementExecutor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
addQuery(T execution)
void
expireQuery(QueryId queryId)
Query is finished and expiration should begin.Collection<T>
getAllQueries()
T
getQuery(QueryId queryId)
void
start()
void
stop()
Optional<T>
tryGetQuery(QueryId queryId)
-
-
-
Constructor Detail
-
QueryTracker
public QueryTracker(QueryManagerConfig queryManagerConfig, ScheduledExecutorService queryManagementExecutor)
-
-
Method Detail
-
start
public void start()
-
stop
public void stop()
-
getAllQueries
public Collection<T> getAllQueries()
-
getQuery
public T getQuery(QueryId queryId) throws NoSuchElementException
- Throws:
NoSuchElementException
-
addQuery
public boolean addQuery(T execution)
-
expireQuery
public void expireQuery(QueryId queryId)
Query is finished and expiration should begin.
-
-