Interface StreamEventSourceProps

All Superinterfaces:
BaseStreamEventSourceProps, software.amazon.jsii.JsiiSerializable
All Known Subinterfaces:
DynamoEventSourceProps, KinesisEventSourceProps
All Known Implementing Classes:
DynamoEventSourceProps.Jsii$Proxy, KinesisEventSourceProps.Jsii$Proxy, StreamEventSourceProps.Jsii$Proxy

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:30:46.849Z") @Stability(Stable) public interface StreamEventSourceProps extends software.amazon.jsii.JsiiSerializable, BaseStreamEventSourceProps
The set of properties for streaming event sources shared by Dynamo and Kinesis.

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.*;
 import software.amazon.awscdk.services.lambda.eventsources.*;
 import software.amazon.awscdk.core.*;
 IEventSourceDlq eventSourceDlq;
 StreamEventSourceProps streamEventSourceProps = StreamEventSourceProps.builder()
         .startingPosition(StartingPosition.TRIM_HORIZON)
         // the properties below are optional
         .batchSize(123)
         .bisectBatchOnError(false)
         .enabled(false)
         .maxBatchingWindow(Duration.minutes(30))
         .maxRecordAge(Duration.minutes(30))
         .onFailure(eventSourceDlq)
         .parallelizationFactor(123)
         .reportBatchItemFailures(false)
         .retryAttempts(123)
         .tumblingWindow(Duration.minutes(30))
         .build();
 
  • Method Details

    • getBisectBatchOnError

      @Stability(Stable) @Nullable default Boolean getBisectBatchOnError()
      If the function returns an error, split the batch in two and retry.

      Default: false

    • getMaxRecordAge

      @Stability(Stable) @Nullable default Duration getMaxRecordAge()
      The maximum age of a record that Lambda sends to a function for processing.

      Valid Range:

      • Minimum value of 60 seconds
      • Maximum value of 7 days

      Default: - the retention period configured on the stream

    • getOnFailure

      @Stability(Stable) @Nullable default IEventSourceDlq getOnFailure()
      An Amazon SQS queue or Amazon SNS topic destination for discarded records.

      Default: - discarded records are ignored

    • getParallelizationFactor

      @Stability(Stable) @Nullable default Number getParallelizationFactor()
      The number of batches to process from each shard concurrently.

      Valid Range:

      • Minimum value of 1
      • Maximum value of 10

      Default: 1

    • getReportBatchItemFailures

      @Stability(Stable) @Nullable default Boolean getReportBatchItemFailures()
      Allow functions to return partially successful responses for a batch of records.

      Default: false

      See Also:
    • getRetryAttempts

      @Stability(Stable) @Nullable default Number getRetryAttempts()
      Maximum number of retry attempts Valid Range: * Minimum value of 0 * Maximum value of 10000.

      Default: - retry until the record expires

    • getTumblingWindow

      @Stability(Stable) @Nullable default Duration getTumblingWindow()
      The size of the tumbling windows to group records sent to DynamoDB or Kinesis Valid Range: 0 - 15 minutes.

      Default: - None

    • builder

      @Stability(Stable) static StreamEventSourceProps.Builder builder()
      Returns:
      a StreamEventSourceProps.Builder of StreamEventSourceProps