Class TaskActivityManager
java.lang.Object
com.evolveum.midpoint.repo.common.activity.TaskActivityManager
Provides common functionality related to activities (something like
TaskManager does for tasks).-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription@Nullable TaskAffectedObjectsTypecomputeAffectedObjects(@Nullable ActivityDefinitionType activityDefinitionBean, AbstractActivityWorkStateType state) Computes affected objects for a given activity definition, either simple or composite.voiddeleteActivityStateAndWorkers(@NotNull String rootTaskOid, boolean deleteWorkers, long subtasksWaitTime, OperationResult parentResult) TODO somehow unify with TaskStatePurger@NotNull Activity<?,?> getActivity(Task rootTask, ActivityPath activityPath) @NotNull com.google.common.collect.Multimap<ActivityPath,OtherActivityState> getAllActivityStates(String rootTaskOid, OperationResult result) Returns all activity state beans in the task tree.getPerformanceInformation(String rootTaskOid, OperationResult result) getProgressInformation(@NotNull String rootTaskOid, @NotNull ActivityProgressInformationBuilder.InformationSource source, @NotNull OperationResult result) getProgressInformationFromTaskTree(String rootTaskOid, OperationResult result) Assumes that the whole task tree is loaded.@NotNull Map<ActivityPath,WorkersReconciliationResultType> reconcileWorkers(@NotNull String rootTaskOid, @NotNull OperationResult parentResult) Note that we reconcile only workers for distributed activities that already have their state.
-
Constructor Details
-
TaskActivityManager
public TaskActivityManager()
-
-
Method Details
-
getProgressInformationFromTaskTree
public ActivityProgressInformation getProgressInformationFromTaskTree(String rootTaskOid, OperationResult result) throws SchemaException, ObjectNotFoundException Assumes that the whole task tree is loaded. -
getProgressInformation
public ActivityProgressInformation getProgressInformation(@NotNull @NotNull String rootTaskOid, @NotNull @NotNull ActivityProgressInformationBuilder.InformationSource source, @NotNull @NotNull OperationResult result) throws SchemaException, ObjectNotFoundException -
getPerformanceInformation
public TreeNode<ActivityPerformanceInformation> getPerformanceInformation(String rootTaskOid, OperationResult result) throws SchemaException, ObjectNotFoundException -
getActivity
@NotNull public @NotNull Activity<?,?> getActivity(Task rootTask, ActivityPath activityPath) throws SchemaException, ConfigurationException -
reconcileWorkers
@NotNull public @NotNull Map<ActivityPath,WorkersReconciliationResultType> reconcileWorkers(@NotNull @NotNull String rootTaskOid, @NotNull @NotNull OperationResult parentResult) throws SchemaException, ObjectNotFoundException Note that we reconcile only workers for distributed activities that already have their state. -
deleteActivityStateAndWorkers
public void deleteActivityStateAndWorkers(@NotNull @NotNull String rootTaskOid, boolean deleteWorkers, long subtasksWaitTime, OperationResult parentResult) throws SchemaException, ObjectNotFoundException TODO somehow unify with TaskStatePurger -
computeAffectedObjects
@Nullable public @Nullable TaskAffectedObjectsType computeAffectedObjects(@Nullable @Nullable ActivityDefinitionType activityDefinitionBean, AbstractActivityWorkStateType state) throws SchemaException, ConfigurationException Computes affected objects for a given activity definition, either simple or composite. -
getAllActivityStates
@NotNull public @NotNull com.google.common.collect.Multimap<ActivityPath,OtherActivityState> getAllActivityStates(String rootTaskOid, OperationResult result) throws SchemaException, ObjectNotFoundException Returns all activity state beans in the task tree. Note that for delegated activities, there are usually two states returned: one from the delegator task and one from the delegate task. In a similar way, for distributed activities, there is usually one state from the coordinator task and multiple states from the worker tasks.
-