public class DriverContext extends Object
Constructor and Description |
---|
DriverContext() |
DriverContext(Context ctx) |
Modifier and Type | Method and Description |
---|---|
boolean |
addToRunnable(Task<? extends Serializable> tsk) |
void |
finished(TaskRunner runner) |
Context |
getCtx() |
int |
getCurJobNo() |
Task<? extends Serializable> |
getRunnable(int maxthreads) |
void |
incCurJobNo(int amount) |
static boolean |
isLaunchable(Task<? extends Serializable> tsk)
Checks if a task can be launched.
|
boolean |
isRunning() |
boolean |
isShutdown() |
void |
launching(TaskRunner runner) |
TaskRunner |
pollFinished()
Polls running tasks to see if a task has ended.
|
void |
prepare(QueryPlan plan) |
void |
prepare(TaskRunner runner) |
void |
remove(Task<? extends Serializable> task) |
void |
shutdown()
Cleans up remaining tasks in case of failure
|
public DriverContext()
public DriverContext(Context ctx)
public boolean isShutdown()
public boolean isRunning()
public void remove(Task<? extends Serializable> task)
public void launching(TaskRunner runner) throws HiveException
HiveException
public Task<? extends Serializable> getRunnable(int maxthreads) throws HiveException
HiveException
public TaskRunner pollFinished() throws InterruptedException
InterruptedException
public void shutdown()
public static boolean isLaunchable(Task<? extends Serializable> tsk)
tsk
- the task to be checkedpublic boolean addToRunnable(Task<? extends Serializable> tsk) throws HiveException
HiveException
public int getCurJobNo()
public Context getCtx()
public void incCurJobNo(int amount)
public void prepare(QueryPlan plan)
public void prepare(TaskRunner runner)
public void finished(TaskRunner runner)
Copyright © 2017 The Apache Software Foundation. All rights reserved.