[undertow-dev] WebSocketChannel getPeerConnections() unnecesary cost?

Mario Carbajal mario.e.carbajal at gmail.com
Fri Feb 10 10:04:25 EST 2017


Undertow websockets mantain a peer connections set
per WebSocketProtocolHandshakeHandler instance. From the looks of it, it's
there only for undertow users convinience.

The application I'm building doesn't make use of the peer connections set
at all and it feels kinda bad to have to pay for the feature despite not
using it.

It would be great if there was a way to disable this functionality. Perhaps
with an overload of the WebSocketProtocolHandshakeHandler constructor that
initializes that set to null. (and adding null checks whenever the set is
used.)
Or maybe some global undertow setting?

This kind of functionality could be provided optionally as a convinience
abstract class that implements WebSocketConnectionCallback and maintains
the set, exposing it to the users by an overrideable overload of the
onConnect method.
Users that want the functionality could inherit from it.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/undertow-dev/attachments/20170210/9d3a227c/attachment.html 


More information about the undertow-dev mailing list