Closed michaelklishin closed 2 years ago
This PR has a syntax error but also makes too many properties weak. The compiler warns of transport
being released right after assignment, for example.
@BarryDuggan do you see the same warnings by any chance?
This unintentionally dropped the delegate property in RMQConnection
as well.
I didnt get any compiler warning related to transport. That said, when I remove weak from transport there is still no retain cycle. Additionally weak is not needed for heartbeatSender or channelZero either
In summary weak can be from:
for some important dependencies of allocated channels and RMQConnection itself.
In this client, RMQConnection auto-allocates a channel for the purpose of special "channel zero" (system communication in the protocol) purposes, and that leads to a loop of strong references that prevent RMQConnection instances from being released.
Contributed by @BarryDuggan in #194.