Page 1 of 1
SFSEventType.USER_DISCONNECT not being fired
Posted: 22 Feb 2012, 13:53
by pankaj454k
Hi,
I am facing a strange issue with SFSEventType.USER_DISCONNECT, it gets fired when I close my browser but it doesn't get into the handler when LAN cable is unplugged or network connection is disabled.
Please Help!
Regards,
Anupam
Re: SFSEventType.USER_DISCONNECT not being fired
Posted: 23 Feb 2012, 10:29
by Bax
When you close the browser, all the connections are correctly ended.
Instead when you abruptly unplug the cable or disable the network connection, the socket connection can't be terminated properly and SFS is not immediately aware that the client isn't there anymore.
The event will be fired later, when a timeout occurs at operating system level.
Re: SFSEventType.USER_DISCONNECT not being fired
Posted: 01 Mar 2012, 13:42
by set_a
Hi
Could you explain me
What kind of events order will be on the server and flash if there's set setting "User reconnection timeframe" = 3
USER_DISCONNECT
USER_RECONNECTION_TRY
USER_RECONNECTION_SUCCESS
user in room in time disconnect
USER_DISCONNECT and USER_LEAVE_ROOM or only USER_DISCONNECT
The event USER_LEAVE_ROOM is running only if user didn't join the room in the proper time?
if the user was the last in the room (the room should be removed if it is empty) and there was a remote Internet connection or the browser was crashed. The room will be deleted immediately or it wait of time set in setting "User reconnection timeframe"
Thanks
Re: SFSEventType.USER_DISCONNECT not being fired
Posted: 01 Mar 2012, 16:42
by Lapo
When HRC is active and a user is disconnected you get the USER_RECONNECTION_TRY event (client and server)
If the client reconnects successfully you will get USER_RECONNECTION_SUCCESS otherwise a regular USER_DISCONNECT will be fired.