Skip to content

Commit 635d3c8

Browse files
committed
Merge branch '6.4' into 7.2
* 6.4: [Messenger] Add consumer name documentation
2 parents 5014c66 + 1119568 commit 635d3c8

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

messenger.rst

+14-1
Original file line numberDiff line numberDiff line change
@@ -1776,7 +1776,20 @@ under the transport in ``messenger.yaml``:
17761776
The Redis consumer group name
17771777

17781778
``consumer`` (default: ``consumer``)
1779-
Consumer name used in Redis
1779+
Consumer name used in Redis. Allows setting an explicit consumer name identifier.
1780+
Recommended in environments with multiple workers to prevent duplicate message
1781+
processing. Typically set via an environment variable:
1782+
1783+
.. code-block:: yaml
1784+
1785+
# config/packages/messenger.yaml
1786+
framework:
1787+
messenger:
1788+
transports:
1789+
redis:
1790+
dsn: '%env(MESSENGER_TRANSPORT_DSN)%'
1791+
options:
1792+
consumer: '%env(MESSENGER_CONSUMER_NAME)%'
17801793
17811794
``auto_setup`` (default: ``true``)
17821795
Whether to create the Redis group automatically

0 commit comments

Comments
 (0)