-
Bug
-
Resolution: Done
-
Major
-
None
-
None
ProtocolConnectionUtils.connectSync calls remoting to connect and receives an IoFuture<Connection>, which it then waits on for, by default, 5 seconds. If the future completes or fails, it's fine. But if it times out connectSync throws an exception without first cancelling the future. This means remoting has no idea the connection isn't going to be used and if the connection ends up getting established it leaks via the chain WorkerThread -> selector -> table of SelectorKeys maintained by Selector -> NioSocketConduit -> NioSocketStreamConnection.
This has the potential to leak the connection on the other side as well, since if the connection was successfully established but never used or closed down by the initiating side it can just sit there.
One place where this can be more problematic is a remote HostController re-connecting to the DomainController after the HC successfully started but then the connection was lost. The HC will loop continually trying to connect. If this problem keeps happening the leaked connection objects will accumulate.
- is cloned by
-
JBEAP-20128 [GSS](7.3.z) WFCORE-5105 - ProtocolConnectionUtils may leak connection objects whose future takes too long to complete (partial fix)
- Closed
- is incorporated by
-
JBEAP-20130 [GSS](7.2.z) WFCORE-5105 - ProtocolConnectionUtils may leak connection objects whose future takes too long to complete
- Closed
- is related to
-
REM3-371 Channel is not closed when one of the peers cancels the connection
- Resolved