Jan Krakora created WICKET-6107:
-----------------------------------

             Summary: Broadcast onClose event regardless of the JSR 356 
WebSocket connection closed state
                 Key: WICKET-6107
                 URL: https://issues.apache.org/jira/browse/WICKET-6107
             Project: Wicket
          Issue Type: Improvement
          Components: wicket-native-websocket
    Affects Versions: 7.2.0
            Reporter: Jan Krakora
            Assignee: Martin Grigorov


When is a WebSocket connection closed, the 
{{org.apache.wicket.protocol.ws.javax.WicketEndpoint.onClose()}} is called. 
This will in turn broadcast an event message to a page that is bound to that 
connection. The problem is when the connection is set to the closed state 
before calling this method - then the event is not broadcasted. See 
{{org.apache.wicket.protocol.ws.api.AbstractWebSocketProcessor.broadcastMessage()}}
 where is checked if the connection is open.

If a client (developer) of the wicket's WebSocket API need to know when a 
connection is closed, there is no chance in the scenario above.

I would suggest to let the {{AbstractWebSocketProcessor}} broadcast the 
ClosedMessage even if the connection is closed.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to