amazon.aws.aws_sqs_queue event source – Receive events via an AWS SQS queue
Note
This EDA event source plugin is part of the amazon.aws collection (version 12.1.0).
You might already have this collection installed if you are using the ansible package.
It is not included in ansible-core.
To check whether it is installed, run ansible-galaxy collection list.
To install it, use: ansible-galaxy collection install amazon.aws.
To use it in a playbook, specify: amazon.aws.aws_sqs_queue.
Synopsis
An ansible-rulebook event source plugin for receiving events via an AWS SQS queue.
This supports all the authentication methods supported by boto3 library: https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html.
Each event is assigned a valid RFC 4122 UUID under meta.uuid.
The SQS MessageId is used directly if it is a valid UUID (AWS guarantees this).
If the MessageId is not a valid UUID, a deterministic UUID5 is generated from the MessageId value. The original value remains accessible under meta.MessageId.
Parameters
Parameter |
Comments |
|---|---|
Optional AWS access key ID. |
|
The SQS long polling duration. Set to Default: |
|
Provided automatically by ansible-rulebook when the feedback parameter is enabled, this parameter utilizes an asyncio.Queue. It allows the system to wait for confirmation that an event has been safely persisted in the database before removing it from the event queue. Users do not need to provide a value for this manually. |
|
Optional URL to connect to instead of the default AWS endpoints. |
|
Should the source plugin wait for feedback before processing the next event from SQS Queue. This flag allows ansible rulebook to pass in an asyncio queue which is passed in the Choices:
|
|
Timeout in seconds to wait for feedback from the rule engine before raising an exception. Only applies when feedback is enabled. Default: |
|
Optional The maximum number of messages to return. Amazon SQS never returns more messages than this value (however, fewer messages might be returned). Valid values are Default: |
|
Name of the queue. |
|
Optional The Amazon Web Services account ID of the account that created the queue. This is only required when you are attempting to access a queue owned by another Amazon Web Services account. |
|
Optional AWS region to use. |
|
Optional AWS secret access key. |
|
Optional STS session token for use with temporary credentials. |
Examples
- amazon.aws.aws_sqs_queue:
region: us-east-1
name: eda
delay_seconds: 10