Commit 8c56020
committed
bug symfony#52896 [Messenger] Avoid reconnecting active Redis connections. (BusterNeece)
This PR was merged into the 5.4 branch.
Discussion
----------
[Messenger] Avoid reconnecting active Redis connections.
| Q | A
| ------------- | ---
| Branch? | 5.4
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Issues | Fix symfony#45057
| License | MIT
With the Messenger component's internal Redis Connection class, if you pass it a \Redis or \Relay instance that's already connected, it will still try to reconnect that instance using the host/port/etc. that's passed to the connection object's "options" array in the constructor.
Not only does this cause problems when the Redis instance is already connected, but it also prevents you from, say, using socket connections instead (as the only connection method supported by the class itself is IP-based connections) and just passing in a ready-to-go Redis instance.
This PR is a resubmission of symfony#52811 targeting 5.4 as it's a bug fix.
Commits
-------
650f153 bug symfony#45057 [Messenger] Avoid reconnecting active Redis connections.File tree
1 file changed
+4
-0
lines changed- src/Symfony/Component/Messenger/Bridge/Redis/Transport
1 file changed
+4
-0
lines changedLines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
117 | 117 | | |
118 | 118 | | |
119 | 119 | | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
120 | 124 | | |
121 | 125 | | |
122 | 126 | | |
| |||
0 commit comments