Package fr.gouv.vitam.processing.model
Class WorkerAsyncRequest
- java.lang.Object
-
- fr.gouv.vitam.processing.model.WorkerAsyncRequest
-
public class WorkerAsyncRequest extends java.lang.Object
Class for manage the launch of an "async" request
-
-
Constructor Summary
Constructors Constructor Description WorkerAsyncRequest(DescriptionStep descriptionStep, Callbackable<WorkerAsyncResponse> callingProcess, java.util.Set<WorkerAsyncRequest> currentRunningObjectsInStep, java.lang.String queueId, java.util.concurrent.Semaphore waitingStepAllAsyncRequest, VitamSession session)
Default constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
callCallback(WorkerAsyncResponse workerAsyncResponse)
call the callback at the end of the processjava.lang.Thread
getCallerThread()
java.util.Set<WorkerAsyncRequest>
getCurrentRunningObjectsInStep()
DescriptionStep
getDescriptionStep()
Arguments of the calljava.lang.String
getQueueID()
VitamSession
getSession()
java.util.concurrent.Semaphore
getWaitingStepAllAsyncRequest()
-
-
-
Constructor Detail
-
WorkerAsyncRequest
public WorkerAsyncRequest(DescriptionStep descriptionStep, Callbackable<WorkerAsyncResponse> callingProcess, java.util.Set<WorkerAsyncRequest> currentRunningObjectsInStep, java.lang.String queueId, java.util.concurrent.Semaphore waitingStepAllAsyncRequest, VitamSession session)
Default constructor- Parameters:
descriptionStep
- the step descriptioncallingProcess
- the callbackcurrentRunningObjectsInStep
- the current object in stepqueueId
- the queue idwaitingStepAllAsyncRequest
- the waiting stepsession
- the session id
-
-
Method Detail
-
getDescriptionStep
public DescriptionStep getDescriptionStep()
Arguments of the call- Returns:
- the descriptionStep
-
callCallback
public void callCallback(WorkerAsyncResponse workerAsyncResponse)
call the callback at the end of the process- Parameters:
workerAsyncResponse
- of typeWorkerAsyncResponse
-
getCallerThread
public java.lang.Thread getCallerThread()
- Returns:
- the Thread of the callerThread (ex: to interrupt it)
-
getCurrentRunningObjectsInStep
public java.util.Set<WorkerAsyncRequest> getCurrentRunningObjectsInStep()
- Returns:
- the currentRunningObjectsInStep
-
getQueueID
public java.lang.String getQueueID()
- Returns:
- the queueID
-
getWaitingStepAllAsyncRequest
public java.util.concurrent.Semaphore getWaitingStepAllAsyncRequest()
- Returns:
- the waitingStepAllAsyncRequest
-
getSession
public VitamSession getSession()
- Returns:
- the session
-
-