Class InvokeOperation<T,I>
java.lang.Object
software.amazon.lambda.durable.operation.BaseDurableOperation
software.amazon.lambda.durable.operation.SerializableDurableOperation<T>
software.amazon.lambda.durable.operation.InvokeOperation<T,I>
- Type Parameters:
T- the result type from the invoked functionI- the payload type sent to the invoked function
- All Implemented Interfaces:
DurableFuture<T>
Durable operation that invokes another Lambda function and waits for its result.
-
Nested Class Summary
Nested classes/interfaces inherited from class software.amazon.lambda.durable.operation.SerializableDurableOperation
SerializableDurableOperation.SerializedResult<T> -
Field Summary
Fields inherited from class software.amazon.lambda.durable.operation.BaseDurableOperation
completionFuture, executionManager, isVirtual, parentOperation, replayCompletedOperation -
Constructor Summary
ConstructorsConstructorDescriptionInvokeOperation(OperationIdentifier operationIdentifier, String functionName, I payload, TypeToken<T> resultTypeToken, InvokeConfig config, DurableContextImpl durableContext) -
Method Summary
Methods inherited from class software.amazon.lambda.durable.operation.SerializableDurableOperation
deserializeException, deserializeResult, serDesContext, serializeAndDeserializeResult, serializeExceptionMethods inherited from class software.amazon.lambda.durable.operation.BaseDurableOperation
deregisterActiveThread, execute, extractErrorFromOperation, fireOnOperationEnd, getChildOperations, getCompletionFuture, getContext, getCurrentThreadContext, getErrorObject, getName, getOperation, getOperationId, getRunningUserHandler, getSubType, getType, interruptRunningUserHandler, isOperationCompleted, isRunningUserHandlerOwner, markAlreadyCompleted, onCheckpointComplete, pollForOperationUpdates, pollForOperationUpdates, processCheckpointUpdate, registerActiveThread, runUserFunction, runUserHandler, sendOperationUpdate, sendOperationUpdateAsync, terminateExecution, terminateExecutionWithIllegalDurableOperationException, validateReplay, waitForFirstOperationCompletion, waitForOperationCompletion
-
Constructor Details
-
InvokeOperation
public InvokeOperation(OperationIdentifier operationIdentifier, String functionName, I payload, TypeToken<T> resultTypeToken, InvokeConfig config, DurableContextImpl durableContext)
-
-
Method Details
-
start
protected void start()Starts the operation.- Specified by:
startin classBaseDurableOperation
-
replay
protected void replay(software.amazon.awssdk.services.lambda.model.Operation existing) Replays the operation.- Specified by:
replayin classBaseDurableOperation- Parameters:
existing- the checkpointed operation state
-
get
Blocks until the operation completes and returns the result.- Specified by:
getin interfaceDurableFuture<T>- Specified by:
getin classSerializableDurableOperation<T>- Returns:
- the operation result
-