public void stopTask(final String id) throws Throwable {
        try {
            executor.submit(new CancelTask(id)).get();
        } catch (ExecutionException e) {
            log.info("stopTask(id={}) error", id, e);
            throw e.getCause();
        }
    }
Stop a task.

@param id                    The ID of the task to stop.
trogdor/src/main/java/org/apache/kafka/trogdor/coordinator/TaskManager.java