Class EventInvokeConfigOptions.Builder
java.lang.Object
software.amazon.awscdk.services.lambda.EventInvokeConfigOptions.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<EventInvokeConfigOptions>
- Enclosing interface:
EventInvokeConfigOptions
@Stability(Stable)
public static final class EventInvokeConfigOptions.Builder
extends Object
implements software.amazon.jsii.Builder<EventInvokeConfigOptions>
A builder for
EventInvokeConfigOptions
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.maxEventAge
(Duration maxEventAge) Sets the value ofEventInvokeConfigOptions.getMaxEventAge()
onFailure
(IDestination onFailure) Sets the value ofEventInvokeConfigOptions.getOnFailure()
onSuccess
(IDestination onSuccess) Sets the value ofEventInvokeConfigOptions.getOnSuccess()
retryAttempts
(Number retryAttempts) Sets the value ofEventInvokeConfigOptions.getRetryAttempts()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
maxEventAge
Sets the value ofEventInvokeConfigOptions.getMaxEventAge()
- Parameters:
maxEventAge
- The maximum age of a request that Lambda sends to a function for processing. Minimum: 60 seconds Maximum: 6 hours- Returns:
this
-
onFailure
Sets the value ofEventInvokeConfigOptions.getOnFailure()
- Parameters:
onFailure
- The destination for failed invocations.- Returns:
this
-
onSuccess
Sets the value ofEventInvokeConfigOptions.getOnSuccess()
- Parameters:
onSuccess
- The destination for successful invocations.- Returns:
this
-
retryAttempts
Sets the value ofEventInvokeConfigOptions.getRetryAttempts()
- Parameters:
retryAttempts
- The maximum number of times to retry when the function returns an error. Minimum: 0 Maximum: 2- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<EventInvokeConfigOptions>
- Returns:
- a new instance of
EventInvokeConfigOptions
- Throws:
NullPointerException
- if any required attribute was not provided
-