public TaskRunner createTaskRunner(Task task, String name) { init(); ExecutorService executor = executorRef.get(); if (executor != null) { return new PooledTaskRunner(executor, task, maxIterationsPerRun); } else { return new DedicatedTaskRunner(task, name, priority, daemon); } }
@Override public void run() { try { runTask(); } finally { LOG.trace("Run task done: {}", task); } } };
/** * shut down the task * * @throws InterruptedException */ @Override public void shutdown() throws InterruptedException { shutdown(0); }
@Override public void run() { try { runTask(); } finally { LOG.trace("Run task done: {}", task); } } };
public TaskRunner createTaskRunner(Task task, String name) { if (executor != null) { return new PooledTaskRunner(executor, task, maxIterationsPerRun); } else { return new DedicatedTaskRunner(task, name, priority, daemon); } }
/** * shut down the task * * @throws InterruptedException */ @Override public void shutdown() throws InterruptedException { shutdown(0); }
@Override public void run() { try { runTask(); } finally { LOG.trace("Run task done: {}", task); } } };
public TaskRunner createTaskRunner(Task task, String name) { init(); ExecutorService executor = executorRef.get(); if (executor != null) { return new PooledTaskRunner(executor, task, maxIterationsPerRun); } else { return new DedicatedTaskRunner(task, name, priority, daemon); } }
/** * shut down the task * * @throws InterruptedException */ @Override public void shutdown() throws InterruptedException { shutdown(0); }
@Override public void run() { try { runTask(); } finally { LOG.trace("Run task done: {}", task); } } };
public TaskRunner createTaskRunner(Task task, String name) { init(); ExecutorService executor = executorRef.get(); if (executor != null) { return new PooledTaskRunner(executor, task, maxIterationsPerRun); } else { return new DedicatedTaskRunner(task, name, priority, daemon); } }
/** * shut down the task * * @throws InterruptedException */ @Override public void shutdown() throws InterruptedException { shutdown(0); }
public void run() { MDCHelper.setContextMap(context); runTask(); } };
public TaskRunner createTaskRunner(Task task, String name) { init(); ExecutorService executor = executorRef.get(); if (executor != null) { return new PooledTaskRunner(executor, task, maxIterationsPerRun); } else { return new DedicatedTaskRunner(task, name, priority, daemon); } }
/** * shut down the task * * @throws InterruptedException */ public void shutdown() throws InterruptedException { shutdown(0); }