Class WorkbasketCleanupJob
- java.lang.Object
-
- pro.taskana.common.internal.jobs.AbstractTaskanaJob
-
- pro.taskana.workbasket.internal.jobs.WorkbasketCleanupJob
-
- All Implemented Interfaces:
TaskanaJob
public class WorkbasketCleanupJob extends AbstractTaskanaJob
Job to cleanup completed workbaskets after a period of time if there are no pending tasks associated to the workbasket.
-
-
Field Summary
-
Fields inherited from class pro.taskana.common.internal.jobs.AbstractTaskanaJob
scheduledJob, taskanaEngineImpl, txProvider
-
-
Constructor Summary
Constructors Constructor Description WorkbasketCleanupJob(TaskanaEngine taskanaEngine, TaskanaTransactionProvider<Object> txProvider, ScheduledJob job)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static voidinitializeSchedule(TaskanaEngine taskanaEngine)Initializes the WorkbasketCleanupJob schedule.voidrun()Runs the TaskanaJob.-
Methods inherited from class pro.taskana.common.internal.jobs.AbstractTaskanaJob
createFromScheduledJob, partition
-
-
-
-
Constructor Detail
-
WorkbasketCleanupJob
public WorkbasketCleanupJob(TaskanaEngine taskanaEngine, TaskanaTransactionProvider<Object> txProvider, ScheduledJob job)
-
-
Method Detail
-
run
public void run() throws TaskanaExceptionDescription copied from interface:TaskanaJobRuns the TaskanaJob.- Throws:
TaskanaException- if an exception occured during the run.
-
initializeSchedule
public static void initializeSchedule(TaskanaEngine taskanaEngine)
Initializes the WorkbasketCleanupJob schedule.
All scheduled cleanup jobs are cancelled/deleted and a new one is scheduled.- Parameters:
taskanaEngine- the taskana engine
-
-