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.
-
Field Summary
Fields inherited from class software.amazon.lambda.durable.operation.BaseDurableOperation
completionFuture, executionManager, parentOperation -
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, serializeException, serializeResultMethods inherited from class software.amazon.lambda.durable.operation.BaseDurableOperation
execute, getChildOperations, getCompletionFuture, getContext, getCurrentThreadContext, getName, getOperation, getOperationId, getSubType, getType, isOperationCompleted, markAlreadyCompleted, onCheckpointComplete, pollForOperationUpdates, pollForOperationUpdates, registerActiveThread, runUserHandler, sendOperationUpdate, sendOperationUpdateAsync, terminateExecution, terminateExecutionWithIllegalDurableOperationException, validateReplay, 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
-