public class TaskRunner extends Object implements Runnable, AutoCloseable
Picks up tasks from the work queue, runs them and marks them as completed or failed.
Runs tasks in a pool. The size of this pool is configurable in the properties file. Controls marking the state of running TaskRunner in Zookeeper.
| Constructor and Description |
|---|
TaskRunner(TaskStateStorage storage,
ZookeeperConnection connection) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Stop the main loop, causing run() to exit.
|
void |
run()
Start the main loop, this will block until a call to stop().
|
public TaskRunner(TaskStateStorage storage, ZookeeperConnection connection)
public void run()
public void close()
close in interface AutoCloseableCopyright © 2017 Grakn Labs Ltd. All rights reserved.