@Generated(value="jsii-pacmak/1.73.0 (build 6faeda3)", date="2023-01-31T18:36:54.396Z") public class CfnEventInvokeConfig extends CfnResource implements IInspectable
The AWS::Lambda::EventInvokeConfig
resource configures options for asynchronous invocation on a version or an alias.
By default, Lambda retries an asynchronous invocation twice if the function returns an error. It retains events in a queue for up to six hours. When an event fails all processing attempts or stays in the asynchronous invocation queue for too long, Lambda discards it.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.services.lambda.*; CfnEventInvokeConfig cfnEventInvokeConfig = CfnEventInvokeConfig.Builder.create(this, "MyCfnEventInvokeConfig") .functionName("functionName") .qualifier("qualifier") // the properties below are optional .destinationConfig(DestinationConfigProperty.builder() .onFailure(OnFailureProperty.builder() .destination("destination") .build()) .onSuccess(OnSuccessProperty.builder() .destination("destination") .build()) .build()) .maximumEventAgeInSeconds(123) .maximumRetryAttempts(123) .build();
Modifier and Type | Class and Description |
---|---|
static class |
CfnEventInvokeConfig.Builder
A fluent builder for
CfnEventInvokeConfig . |
static interface |
CfnEventInvokeConfig.DestinationConfigProperty
A configuration object that specifies the destination of an event after Lambda processes it.
|
static interface |
CfnEventInvokeConfig.OnFailureProperty
A destination for events that failed processing.
|
static interface |
CfnEventInvokeConfig.OnSuccessProperty
A destination for events that were processed successfully.
|
IInspectable.Jsii$Default, IInspectable.Jsii$Proxy
IConstruct.Jsii$Default
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
|
Modifier | Constructor and Description |
---|---|
|
CfnEventInvokeConfig(Construct scope,
java.lang.String id,
CfnEventInvokeConfigProps props)
Create a new `AWS::Lambda::EventInvokeConfig`.
|
protected |
CfnEventInvokeConfig(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
CfnEventInvokeConfig(software.amazon.jsii.JsiiObjectRef objRef) |
Modifier and Type | Method and Description |
---|---|
protected java.util.Map<java.lang.String,java.lang.Object> |
getCfnProperties() |
java.lang.Object |
getDestinationConfig()
A destination for events after they have been sent to a function for processing.
|
java.lang.String |
getFunctionName()
The name of the Lambda function.
|
java.lang.Number |
getMaximumEventAgeInSeconds()
The maximum age of a request that Lambda sends to a function for processing.
|
java.lang.Number |
getMaximumRetryAttempts()
The maximum number of times to retry when the function returns an error.
|
java.lang.String |
getQualifier()
The identifier of a version or alias.
|
void |
inspect(TreeInspector inspector)
Examines the CloudFormation resource and discloses attributes.
|
protected java.util.Map<java.lang.String,java.lang.Object> |
renderProperties(java.util.Map<java.lang.String,java.lang.Object> props) |
void |
setDestinationConfig(CfnEventInvokeConfig.DestinationConfigProperty value)
A destination for events after they have been sent to a function for processing.
|
void |
setDestinationConfig(IResolvable value)
A destination for events after they have been sent to a function for processing.
|
void |
setFunctionName(java.lang.String value)
The name of the Lambda function.
|
void |
setMaximumEventAgeInSeconds(java.lang.Number value)
The maximum age of a request that Lambda sends to a function for processing.
|
void |
setMaximumRetryAttempts(java.lang.Number value)
The maximum number of times to retry when the function returns an error.
|
void |
setQualifier(java.lang.String value)
The identifier of a version or alias.
|
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, isCfnResource, shouldSynthesize, toString, validateProperties
getRef
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalId
getNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize, validate
public static final java.lang.String CFN_RESOURCE_TYPE_NAME
protected CfnEventInvokeConfig(software.amazon.jsii.JsiiObjectRef objRef)
protected CfnEventInvokeConfig(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
public CfnEventInvokeConfig(Construct scope, java.lang.String id, CfnEventInvokeConfigProps props)
scope
- - scope in which this resource is defined. This parameter is required.id
- - scoped id of the resource. This parameter is required.props
- - resource properties. This parameter is required.public void inspect(TreeInspector inspector)
inspect
in interface IInspectable
inspector
- - tree inspector to collect and process attributes. This parameter is required.protected java.util.Map<java.lang.String,java.lang.Object> renderProperties(java.util.Map<java.lang.String,java.lang.Object> props)
renderProperties
in class CfnResource
props
- This parameter is required.protected java.util.Map<java.lang.String,java.lang.Object> getCfnProperties()
getCfnProperties
in class CfnResource
public java.lang.String getFunctionName()
Minimum : 1
Maximum : 64
Pattern : ([a-zA-Z0-9-_]+)
public void setFunctionName(java.lang.String value)
Minimum : 1
Maximum : 64
Pattern : ([a-zA-Z0-9-_]+)
public java.lang.String getQualifier()
$LATEST
.public void setQualifier(java.lang.String value)
$LATEST
.public java.lang.Object getDestinationConfig()
Destinations - Function - The Amazon Resource Name (ARN) of a Lambda function.
public void setDestinationConfig(IResolvable value)
Destinations - Function - The Amazon Resource Name (ARN) of a Lambda function.
public void setDestinationConfig(CfnEventInvokeConfig.DestinationConfigProperty value)
Destinations - Function - The Amazon Resource Name (ARN) of a Lambda function.
public java.lang.Number getMaximumEventAgeInSeconds()
public void setMaximumEventAgeInSeconds(java.lang.Number value)
public java.lang.Number getMaximumRetryAttempts()
public void setMaximumRetryAttempts(java.lang.Number value)