Skip to content

[Messenger] Add options to specify SQS queue attributes and tags #59822

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 21, 2025

Conversation

TrePe0
Copy link
Contributor

@TrePe0 TrePe0 commented Feb 21, 2025

Q A
Branch? 7.3
Bug fix? no
New feature? yes
Deprecations? no
Issues
License MIT

When automatically creating SQS queue, the new options queue_attributes and queue_tags can be used to specify queue attributes and cost allocation tags as per SQS CreateQueue API

Usage example:

$queueName = 'queueName.fifo';
$queueAttributes = [
    QueueAttributeName::MESSAGE_RETENTION_PERIOD => '900',
    QueueAttributeName::MAXIMUM_MESSAGE_SIZE => '1024',
];
$queueTags = ['tag1' => 'value1', 'tag2' => 'value2'];

$connection = new Connection(['queue_name' => $queueName, 'queue_attributes' => $queueAttributes, 'queue_tags' => $queueTags], $client);

@nicolas-grekas
Copy link
Member

Thank you @TrePe0.

@nicolas-grekas nicolas-grekas force-pushed the feat/sqs-queue-attributes branch from 186b480 to 99e3f4d Compare February 21, 2025 09:16
@nicolas-grekas nicolas-grekas merged commit 0fc079f into symfony:7.3 Feb 21, 2025
2 checks passed
@TrePe0
Copy link
Contributor Author

TrePe0 commented Feb 21, 2025

Thanks @nicolas-grekas for quick review. Going to update the doc now.

@fabpot fabpot mentioned this pull request May 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants