You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In NioWebSocketMessageChannel.processMessage() there's a call to NioTcpMessageProcessor.assignChannelToDestination() which ultimately adds an entry to ConnectionOrientedMessageProcessor.messageChannels with a key from the Contact header of the REGISTER request.
But this key never seems to be removed because the Channel's .getKey() returns a different key, and as far as I can tell the map is only cleaned up by removing the keys that the channels specify. The contact hostname is just some '.invalid' hostname so a key of, e.g. "wss:s03k4bate5k0.invalid:5060" is inserted into the map, but the channel's .getKey() returns "wss:127.0.0.1:40144".
And I believe an entry with the key "wss:127.0.0.1:40144" is inserted into the map by NioWebSocketMessageProcessor.CreateChannel() which is cleaned up because it matches the Channel's own idea of what its key is.
There should be no need for the stack to keep the mapping of Contact to socket connections as this should be done at the application level using RFC 5626 as described in RFC7118
The text was updated successfully, but these errors were encountered:
JSIP-504
Removing code that lead to the mem leak on WebSocket Channel with REGISTER. Contribution from Michael Groshans
git-svn-id: https://svn.java.net/svn/jsip~svn/trunk@2380 8e71dc83-d81e-6649-80f2-80b843a9b2be
In NioWebSocketMessageChannel.processMessage() there's a call to NioTcpMessageProcessor.assignChannelToDestination() which ultimately adds an entry to ConnectionOrientedMessageProcessor.messageChannels with a key from the Contact header of the REGISTER request.
But this key never seems to be removed because the Channel's .getKey() returns a different key, and as far as I can tell the map is only cleaned up by removing the keys that the channels specify. The contact hostname is just some '.invalid' hostname so a key of, e.g. "wss:s03k4bate5k0.invalid:5060" is inserted into the map, but the channel's .getKey() returns "wss:127.0.0.1:40144".
And I believe an entry with the key "wss:127.0.0.1:40144" is inserted into the map by NioWebSocketMessageProcessor.CreateChannel() which is cleaned up because it matches the Channel's own idea of what its key is.
There should be no need for the stack to keep the mapping of Contact to socket connections as this should be done at the application level using RFC 5626 as described in RFC7118
The text was updated successfully, but these errors were encountered: