com.evolveum.midpoint.task.quartzimpl.execution
Class TaskSynchronizer

java.lang.Object
  extended by com.evolveum.midpoint.task.quartzimpl.execution.TaskSynchronizer

public class TaskSynchronizer
extends Object

Synchronizes midPoint repository with Quartz job store. The mapping between tasks in repo and jobs in Quartz looks like this: 1) each task corresponds to a job; job name = task oid, job group = DEFAULT TODO: should waiting/closed tasks have their jobs? At minimum, we do not create them if they do not exist 2) each task has 0, 1 or 2 triggers - if task is RUNNABLE, it has 1 or 2 triggers (one trigger is standard, with trigger name = task oid, trigger group = DEFAULT; second trigger is optional, used by Quartz when recovering the task) - if task is WAITING or CLOSED, it has 0 triggers - if task is SUSPENDED, it can have 0 to 2 triggers - 0 if the job was created when task was in SUSPENDED state - 1 or 2 if a RUNNABLE task was SUSPENDED (triggers were kept in order to be un-paused when task is resumed)

Author:
Pavol Mederly

Constructor Summary
TaskSynchronizer(TaskManagerQuartzImpl taskManager)
           
 
Method Summary
 boolean synchronizeTask(TaskQuartzImpl task, OperationResult parentResult)
          Task should be refreshed when entering this method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TaskSynchronizer

public TaskSynchronizer(TaskManagerQuartzImpl taskManager)
Method Detail

synchronizeTask

public boolean synchronizeTask(TaskQuartzImpl task,
                               OperationResult parentResult)
Task should be refreshed when entering this method.

Returns:
true if task info in Quartz was updated


Copyright © 2013 evolveum. All Rights Reserved.