|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface LongRunningTaskManager
Coordinates the creation and maintenance of batch jobs that last longer than a single web request
| Method Summary | |
|---|---|
com.atlassian.core.task.longrunning.LongRunningTask |
getLongRunningTask(com.atlassian.user.User user,
LongRunningTaskId id)
Retrieve a previously started task. |
void |
resume()
Resume accepting long-running tasks after stop(long, java.util.concurrent.TimeUnit) has been called. |
LongRunningTaskId |
startLongRunningTask(com.atlassian.user.User user,
com.atlassian.core.task.longrunning.LongRunningTask task)
Start some task in a new thread |
void |
stop(long timeout,
TimeUnit unit)
Stop accepting new long running tasks. |
void |
stopTrackingLongRunningTask(LongRunningTaskId id)
Clean up an old task. |
| Method Detail |
|---|
LongRunningTaskId startLongRunningTask(com.atlassian.user.User user,
com.atlassian.core.task.longrunning.LongRunningTask task)
user - the user responsible for the tasktask - the task to perform
IllegalStateException - if the task manager has been shut down
com.atlassian.core.task.longrunning.LongRunningTask getLongRunningTask(com.atlassian.user.User user,
LongRunningTaskId id)
user - the user responsible for the taskid - the ID of the task
void stopTrackingLongRunningTask(LongRunningTaskId id)
This method does not stop a task from being executed. If the task is already running it will continue to completion, you just won't be able to query its status any more.
id - the ID of the task to remove.
void stop(long timeout,
TimeUnit unit)
throws TimeoutException
timeout - the time to wait for running tasks to completeunit - the unit of measurement for the timeout parameter
TimeoutException - if the timeout is exceededvoid resume()
stop(long, java.util.concurrent.TimeUnit) has been called. If
the long-running task manager is not stopped, this method will whistle
quietly to itself and do nothing.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||