/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace Pipes { namespace Model { /** *

The parameters for using a DynamoDB stream as a source.

See * Also:

AWS * API Reference

*/ class UpdatePipeSourceDynamoDBStreamParameters { public: AWS_PIPES_API UpdatePipeSourceDynamoDBStreamParameters(); AWS_PIPES_API UpdatePipeSourceDynamoDBStreamParameters(Aws::Utils::Json::JsonView jsonValue); AWS_PIPES_API UpdatePipeSourceDynamoDBStreamParameters& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_PIPES_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

The maximum number of records to include in each batch.

*/ inline int GetBatchSize() const{ return m_batchSize; } /** *

The maximum number of records to include in each batch.

*/ inline bool BatchSizeHasBeenSet() const { return m_batchSizeHasBeenSet; } /** *

The maximum number of records to include in each batch.

*/ inline void SetBatchSize(int value) { m_batchSizeHasBeenSet = true; m_batchSize = value; } /** *

The maximum number of records to include in each batch.

*/ inline UpdatePipeSourceDynamoDBStreamParameters& WithBatchSize(int value) { SetBatchSize(value); return *this;} /** *

Define the target queue to send dead-letter queue events to.

*/ inline const DeadLetterConfig& GetDeadLetterConfig() const{ return m_deadLetterConfig; } /** *

Define the target queue to send dead-letter queue events to.

*/ inline bool DeadLetterConfigHasBeenSet() const { return m_deadLetterConfigHasBeenSet; } /** *

Define the target queue to send dead-letter queue events to.

*/ inline void SetDeadLetterConfig(const DeadLetterConfig& value) { m_deadLetterConfigHasBeenSet = true; m_deadLetterConfig = value; } /** *

Define the target queue to send dead-letter queue events to.

*/ inline void SetDeadLetterConfig(DeadLetterConfig&& value) { m_deadLetterConfigHasBeenSet = true; m_deadLetterConfig = std::move(value); } /** *

Define the target queue to send dead-letter queue events to.

*/ inline UpdatePipeSourceDynamoDBStreamParameters& WithDeadLetterConfig(const DeadLetterConfig& value) { SetDeadLetterConfig(value); return *this;} /** *

Define the target queue to send dead-letter queue events to.

*/ inline UpdatePipeSourceDynamoDBStreamParameters& WithDeadLetterConfig(DeadLetterConfig&& value) { SetDeadLetterConfig(std::move(value)); return *this;} /** *

The maximum length of a time to wait for events.

*/ inline int GetMaximumBatchingWindowInSeconds() const{ return m_maximumBatchingWindowInSeconds; } /** *

The maximum length of a time to wait for events.

*/ inline bool MaximumBatchingWindowInSecondsHasBeenSet() const { return m_maximumBatchingWindowInSecondsHasBeenSet; } /** *

The maximum length of a time to wait for events.

*/ inline void SetMaximumBatchingWindowInSeconds(int value) { m_maximumBatchingWindowInSecondsHasBeenSet = true; m_maximumBatchingWindowInSeconds = value; } /** *

The maximum length of a time to wait for events.

*/ inline UpdatePipeSourceDynamoDBStreamParameters& WithMaximumBatchingWindowInSeconds(int value) { SetMaximumBatchingWindowInSeconds(value); return *this;} /** *

(Streams only) Discard records older than the specified age. The default * value is -1, which sets the maximum age to infinite. When the value is set to * infinite, EventBridge never discards old records.

*/ inline int GetMaximumRecordAgeInSeconds() const{ return m_maximumRecordAgeInSeconds; } /** *

(Streams only) Discard records older than the specified age. The default * value is -1, which sets the maximum age to infinite. When the value is set to * infinite, EventBridge never discards old records.

*/ inline bool MaximumRecordAgeInSecondsHasBeenSet() const { return m_maximumRecordAgeInSecondsHasBeenSet; } /** *

(Streams only) Discard records older than the specified age. The default * value is -1, which sets the maximum age to infinite. When the value is set to * infinite, EventBridge never discards old records.

*/ inline void SetMaximumRecordAgeInSeconds(int value) { m_maximumRecordAgeInSecondsHasBeenSet = true; m_maximumRecordAgeInSeconds = value; } /** *

(Streams only) Discard records older than the specified age. The default * value is -1, which sets the maximum age to infinite. When the value is set to * infinite, EventBridge never discards old records.

*/ inline UpdatePipeSourceDynamoDBStreamParameters& WithMaximumRecordAgeInSeconds(int value) { SetMaximumRecordAgeInSeconds(value); return *this;} /** *

(Streams only) Discard records after the specified number of retries. The * default value is -1, which sets the maximum number of retries to infinite. When * MaximumRetryAttempts is infinite, EventBridge retries failed records until the * record expires in the event source.

*/ inline int GetMaximumRetryAttempts() const{ return m_maximumRetryAttempts; } /** *

(Streams only) Discard records after the specified number of retries. The * default value is -1, which sets the maximum number of retries to infinite. When * MaximumRetryAttempts is infinite, EventBridge retries failed records until the * record expires in the event source.

*/ inline bool MaximumRetryAttemptsHasBeenSet() const { return m_maximumRetryAttemptsHasBeenSet; } /** *

(Streams only) Discard records after the specified number of retries. The * default value is -1, which sets the maximum number of retries to infinite. When * MaximumRetryAttempts is infinite, EventBridge retries failed records until the * record expires in the event source.

*/ inline void SetMaximumRetryAttempts(int value) { m_maximumRetryAttemptsHasBeenSet = true; m_maximumRetryAttempts = value; } /** *

(Streams only) Discard records after the specified number of retries. The * default value is -1, which sets the maximum number of retries to infinite. When * MaximumRetryAttempts is infinite, EventBridge retries failed records until the * record expires in the event source.

*/ inline UpdatePipeSourceDynamoDBStreamParameters& WithMaximumRetryAttempts(int value) { SetMaximumRetryAttempts(value); return *this;} /** *

(Streams only) Define how to handle item process failures. * AUTOMATIC_BISECT halves each batch and retry each half until all * the records are processed or there is one failed message left in the batch.

*/ inline const OnPartialBatchItemFailureStreams& GetOnPartialBatchItemFailure() const{ return m_onPartialBatchItemFailure; } /** *

(Streams only) Define how to handle item process failures. * AUTOMATIC_BISECT halves each batch and retry each half until all * the records are processed or there is one failed message left in the batch.

*/ inline bool OnPartialBatchItemFailureHasBeenSet() const { return m_onPartialBatchItemFailureHasBeenSet; } /** *

(Streams only) Define how to handle item process failures. * AUTOMATIC_BISECT halves each batch and retry each half until all * the records are processed or there is one failed message left in the batch.

*/ inline void SetOnPartialBatchItemFailure(const OnPartialBatchItemFailureStreams& value) { m_onPartialBatchItemFailureHasBeenSet = true; m_onPartialBatchItemFailure = value; } /** *

(Streams only) Define how to handle item process failures. * AUTOMATIC_BISECT halves each batch and retry each half until all * the records are processed or there is one failed message left in the batch.

*/ inline void SetOnPartialBatchItemFailure(OnPartialBatchItemFailureStreams&& value) { m_onPartialBatchItemFailureHasBeenSet = true; m_onPartialBatchItemFailure = std::move(value); } /** *

(Streams only) Define how to handle item process failures. * AUTOMATIC_BISECT halves each batch and retry each half until all * the records are processed or there is one failed message left in the batch.

*/ inline UpdatePipeSourceDynamoDBStreamParameters& WithOnPartialBatchItemFailure(const OnPartialBatchItemFailureStreams& value) { SetOnPartialBatchItemFailure(value); return *this;} /** *

(Streams only) Define how to handle item process failures. * AUTOMATIC_BISECT halves each batch and retry each half until all * the records are processed or there is one failed message left in the batch.

*/ inline UpdatePipeSourceDynamoDBStreamParameters& WithOnPartialBatchItemFailure(OnPartialBatchItemFailureStreams&& value) { SetOnPartialBatchItemFailure(std::move(value)); return *this;} /** *

(Streams only) The number of batches to process concurrently from each shard. * The default value is 1.

*/ inline int GetParallelizationFactor() const{ return m_parallelizationFactor; } /** *

(Streams only) The number of batches to process concurrently from each shard. * The default value is 1.

*/ inline bool ParallelizationFactorHasBeenSet() const { return m_parallelizationFactorHasBeenSet; } /** *

(Streams only) The number of batches to process concurrently from each shard. * The default value is 1.

*/ inline void SetParallelizationFactor(int value) { m_parallelizationFactorHasBeenSet = true; m_parallelizationFactor = value; } /** *

(Streams only) The number of batches to process concurrently from each shard. * The default value is 1.

*/ inline UpdatePipeSourceDynamoDBStreamParameters& WithParallelizationFactor(int value) { SetParallelizationFactor(value); return *this;} private: int m_batchSize; bool m_batchSizeHasBeenSet = false; DeadLetterConfig m_deadLetterConfig; bool m_deadLetterConfigHasBeenSet = false; int m_maximumBatchingWindowInSeconds; bool m_maximumBatchingWindowInSecondsHasBeenSet = false; int m_maximumRecordAgeInSeconds; bool m_maximumRecordAgeInSecondsHasBeenSet = false; int m_maximumRetryAttempts; bool m_maximumRetryAttemptsHasBeenSet = false; OnPartialBatchItemFailureStreams m_onPartialBatchItemFailure; bool m_onPartialBatchItemFailureHasBeenSet = false; int m_parallelizationFactor; bool m_parallelizationFactorHasBeenSet = false; }; } // namespace Model } // namespace Pipes } // namespace Aws