public class

TaskDriver

extends Object
java.lang.Object
   ↳ org.apache.helix.task.TaskDriver

Class Overview

CLI for scheduling/canceling workflows

Summary

Nested Classes
enum TaskDriver.DriverCommand Commands which may be parsed from the first argument to main  
Public Constructors
TaskDriver(HelixManager manager)
TaskDriver(ZkClient client, String clusterName)
TaskDriver(ZkClient client, ZkBaseDataAccessor<ZNRecord> baseAccessor, String clusterName)
TaskDriver(HelixAdmin admin, HelixDataAccessor accessor, ConfigAccessor cfgAccessor, HelixPropertyStore<ZNRecord> propertyStore, String clusterName)
Public Methods
void createQueue(JobQueue queue)
Creates a new named job queue (workflow)
void delete(String workflow)
Public method to delete a workflow/queue
void deleteJob(String queueName, String jobName)
Delete a job from an existing named queue, the queue has to be stopped prior to this call
void enqueueJob(String queueName, String jobName, JobConfig.Builder jobBuilder)
Adds a new job to the end an existing named queue
void flushQueue(String queueName)
Flushes a named job queue
void invokeRebalance()
Hack to invoke rebalance until bug concerning resource config changes not driving rebalance is fixed
void list(String resource)
static void main(String[] args)
Parses the first argument as a driver command and the rest of the arguments are parsed based on that command.
void resume(String workflow)
Public method to resume a workflow/queue
void start(Workflow flow)
Schedules a new workflow
void stop(String workflow)
Public method to stop a workflow/queue
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public TaskDriver (HelixManager manager)

public TaskDriver (ZkClient client, String clusterName)

public TaskDriver (ZkClient client, ZkBaseDataAccessor<ZNRecord> baseAccessor, String clusterName)

public TaskDriver (HelixAdmin admin, HelixDataAccessor accessor, ConfigAccessor cfgAccessor, HelixPropertyStore<ZNRecord> propertyStore, String clusterName)

Public Methods

public void createQueue (JobQueue queue)

Creates a new named job queue (workflow)

Throws
Exception

public void delete (String workflow)

Public method to delete a workflow/queue

public void deleteJob (String queueName, String jobName)

Delete a job from an existing named queue, the queue has to be stopped prior to this call

public void enqueueJob (String queueName, String jobName, JobConfig.Builder jobBuilder)

Adds a new job to the end an existing named queue

Throws
Exception

public void flushQueue (String queueName)

Flushes a named job queue

Throws
Exception

public void invokeRebalance ()

Hack to invoke rebalance until bug concerning resource config changes not driving rebalance is fixed

public void list (String resource)

public static void main (String[] args)

Parses the first argument as a driver command and the rest of the arguments are parsed based on that command. Constructs a Helix message and posts it to the controller

Throws
Exception

public void resume (String workflow)

Public method to resume a workflow/queue

public void start (Workflow flow)

Schedules a new workflow

Throws
Exception

public void stop (String workflow)

Public method to stop a workflow/queue