View a markdown version of this page

AWS::Kinesis::Queue - Amazon CloudFormation
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

This is the new Amazon CloudFormation Template Reference Guide. Please update your bookmarks and links. For help getting started with CloudFormation, see the Amazon CloudFormation User Guide.

AWS::Kinesis::Queue

Creates a queue on the specified data stream. A queue delivers records from the stream to a queue consumer, tracks the delivery state of each record, and redelivers any record that is not acknowledged before its visibility timeout expires.

A queue does not extend how long the stream keeps a record. When a record reaches the end of the data stream's retention period, the queue stops delivering it.

Your queue consumer calls ReceiveQueueRecords to receive up to 10 records at a time. After it processes records, it calls AcknowledgeQueueRecords so the queue does not deliver them again.

Queues are supported only on data streams in on-demand capacity mode.

Creating a queue does not change how producers write to the stream, and it does not change how existing stream consumers read from it. A queue counts as a registered consumer on the stream and shares the stream's registered consumer limit with enhanced fan-out consumers: 20 on On-demand Standard and 50 on On-demand Advantage.

Use StartingPosition to set the position in the stream where delivery begins. The default is LATEST.

CreateQueue is an asynchronous operation. Upon receiving a CreateQueue request, Amazon Kinesis Data Streams immediately returns a queue description with a QueueStatus of CREATING. After the queue is created, Kinesis Data Streams sets the QueueStatus to ACTIVE. You can begin receiving records after the queue is ACTIVE. Use DescribeQueue to check the status of the queue.

Each queue has built-in dead-letter handling. When a record has been received MaxReceiveCount times without being acknowledged, it becomes a dead-letter record, and ReceiveQueueRecords no longer returns it. You work with dead-letter records through a separate set of operations that use the same queue ARN: ReceiveDeadLetterQueueRecords, AcknowledgeDeadLetterQueueRecords, UpdateDeadLetterQueueRecordsVisibility, and RestoreDeadLetterQueueRecords.

Dead-letter handling is enabled by default, with a MaxReceiveCount of 6. To use a different value, or to turn dead-letter handling off, specify DeadLetterConfiguration in QueueAttributes.

Syntax

To declare this entity in your Amazon CloudFormation template, use the following syntax:

JSON

{ "Type" : "AWS::Kinesis::Queue", "Properties" : { "QueueAttributes" : QueueAttributes, "QueueName" : String, "StreamConfigurationList" : [ QueueStreamConfiguration, ... ], "Tags" : [ Tag, ... ] } }

YAML

Type: AWS::Kinesis::Queue Properties: QueueAttributes: QueueAttributes QueueName: String StreamConfigurationList: - QueueStreamConfiguration Tags: - Tag

Properties

QueueAttributes

The configuration attributes of the queue.

Required: No

Type: QueueAttributes

Update requires: No interruption

QueueName

The name of the queue.

Required: Yes

Type: String

Pattern: ^[a-zA-Z0-9_.-]+$

Minimum: 1

Maximum: 128

Update requires: Replacement

StreamConfigurationList

The data stream the queue delivers records from, and the position in that stream where delivery begins. The list contains exactly one entry, because a queue delivers records from a single data stream.

Required: Yes

Type: Array of QueueStreamConfiguration

Minimum: 1

Maximum: 10000

Update requires: Replacement

Tags

Property description not available.

Required: No

Type: Array of Tag

Maximum: 50

Update requires: No interruption

Return values

Ref

Fn::GetAtt

QueueARN

The ARN of the queue. The resource identifier in the ARN is generated when the queue is created and is not derived from QueueName. Use the returned QueueARN to identify the queue in subsequent requests.

QueueCreationTimestamp

The time the queue was created.

QueueStatus

The current status of the queue.