Class ProcessingCoordinator<I>
- java.lang.Object
-
- com.evolveum.midpoint.repo.common.activity.run.processing.ProcessingCoordinator<I>
-
public class ProcessingCoordinator<I> extends Object
Responsible for distributing instances ofItemProcessingRequest
to individual worker threads.
-
-
Constructor Summary
Constructors Constructor Description ProcessingCoordinator(int threadsCount, @NotNull IterativeActivityRun<I,?,?,?> activityRun)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
createWorkerThreads()
void
finishProcessing(OperationResult result)
Tells the workers that they should not expect any more work and waits for their completion (which can occur either because of queue is empty or because canRun is false).boolean
isMultithreaded()
boolean
submit(ItemProcessingRequest<I> request, OperationResult result)
-
-
-
Constructor Detail
-
ProcessingCoordinator
public ProcessingCoordinator(int threadsCount, @NotNull @NotNull IterativeActivityRun<I,?,?,?> activityRun)
-
-
Method Detail
-
submit
public boolean submit(ItemProcessingRequest<I> request, OperationResult result)
-
createWorkerThreads
public void createWorkerThreads()
-
isMultithreaded
public boolean isMultithreaded()
-
finishProcessing
public void finishProcessing(OperationResult result)
Tells the workers that they should not expect any more work and waits for their completion (which can occur either because of queue is empty or because canRun is false). Acknowledges any pending requests.
-
-