Commit 15b5097
committed
feature #48603 [Messenger][Amqp] Add config option 'arguments' for delay queues (Thomas Beaujean)
This PR was merged into the 7.1 branch.
Discussion
----------
[Messenger][Amqp] Add config option 'arguments' for delay queues
| Q | A
| ------------- | ---
| Branch? | 6.3
| Bug fix? | no
| New feature? | yes
| Deprecations? | no
| Tickets | Fix #44186 #46254
| License | MIT
| Doc PR | symfony/symfony-docs#17553
Hi, this PR to allow to add extra arguments to the amqp delay queues that are automatically created.
The use case:
- I do not know in advance the name of the queues (handled by env variables)
- The queues are created automatically by symfony if needed
- I need the deduplication plugin in both the queue and the associated delays queues (enabled with the x-message-deduplication argument)
- I do not want to rewrite all delay arguments, I just want to be able to add or rewrite some
The associated configuration in messenger.yaml
```
transports:
async:
dsn: '%env(MESSENGER_DSN)%'
options:
queues:
'%env(MESSENGER_ASYNC_QUEUE_NAME)%':
arguments:
x-queue-type: 'classic'
x-message-deduplication: true
delay:
arguments:
x-queue-type: 'classic'
x-message-deduplication: true
```
Commits
-------
94ee8a22b5 [Messenger] Add config option 'arguments' for delay queuesFile tree
3 files changed
+14
-2
lines changed- Tests/Transport
- Transport
3 files changed
+14
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
4 | 9 | | |
5 | 10 | | |
6 | 11 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
185 | 185 | | |
186 | 186 | | |
187 | 187 | | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
188 | 194 | | |
189 | 195 | | |
190 | 196 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
| 146 | + | |
146 | 147 | | |
147 | 148 | | |
148 | 149 | | |
| |||
387 | 388 | | |
388 | 389 | | |
389 | 390 | | |
390 | | - | |
| 391 | + | |
391 | 392 | | |
392 | 393 | | |
393 | 394 | | |
| |||
398 | 399 | | |
399 | 400 | | |
400 | 401 | | |
401 | | - | |
| 402 | + | |
402 | 403 | | |
403 | 404 | | |
404 | 405 | | |
| |||
0 commit comments