Project

General

Profile

websocket disconnected when browser refreshes

nurnabi siddique
Added almost 5 years ago

i was playing around web socket connection manager of tigase with websocket browser client. what is happening when browser refreshes connection dismissed. so is it any bug?


Replies (3)

Avatar?id=6023&size=32x32

Added by Artur Hefczyc TigaseTeam almost 5 years ago

I am sorry I do not understand, what is the problem exactly? Could you describe it and provide more details?

Added by nurnabi siddique almost 5 years ago

when i refresh browser, websocket sending session close event to tigase server. can you understand now?

Added by Andrzej Wójcik IoT 1 CloudTigaseTeam almost 5 years ago

This is valid behavior of websocket connection manager as when you hit refresh button then browser (on it's own) closes websocket connection. This is what browser does. On server side Tigase XMPP Server and it's websocket connection manager only receives information that connection was broken and since there is no other valid thing to do it closes session related to this connection.

From server end refresh of a browser or disconnection or broken connection looks the same - there is no way to know what really happend. Current draft of specification which describes XMPP connection over WebSocket does not cover solution for page refreshes, but I suppose that it may be solved later by using Stream Management extension of XMPP protocol.

    (1-3/3)