Issue Details (XML | Word | Printable)

Key: TYRUS-229
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: stepan.kopriva
Reporter: martinandersson.com
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
tyrus

Session#setMaxIdleTimeout() will kill the session whether or not the session actually timed out

Created: 06/Aug/13 12:11 PM   Updated: 09/Aug/13 07:21 AM   Resolved: 09/Aug/13 07:21 AM
Component/s: None
Affects Version/s: 1.0-b05, 1.0-b06, 1.0-b07, 1.0-b08, 1.0-b09, 1.0-b10, 1.0-b11, 1.0-b12, 1.0-b13, 1.0-b14, 1.0-rc1, 1.0-rc2, 1.0-rc3, 1.0-rc4, 1.0, 1.1, 1.2, 1.2.1
Fix Version/s: 1.3

Time Tracking:
Not Specified

Environment:

Windows 8 x64, GlassFish 4


Tags:
Participants: martinandersson.com, Pavel Bucek and stepan.kopriva


 Description  « Hide

If you on the server side, grab the websocket session object from the @OnOpen method and call Session#setMaxIdleTimeout() using any number, when that time has passed Tyrus will forcefully close the session whether he actually timed out or not.

To test this, I registered a pong message handler who logged each time we received a pong. It showed that Internet Explorer (10), is the only browser who will send us a pong from time to time. Yet, this browser too will be affected by the aforementioned problem. Furthermore, I setup a scheduled timer to programmatically ping the client endpoint using RemoteEndpoint#sendPing(). That made all the browsers reply with a ping. However, as soon as the time passed that we had sent as an argument to the Session#setMaxIdleTimeout() method, Tyrus closed all sessions despite them being provably not idle.



martinandersson.com added a comment - 06/Aug/13 12:15 PM

It is said in the description: "That made all the browsers reply with a ping."

It should say "That made all the browsers reply with a PONG."

..but I haven't found a way to update the description.


Pavel Bucek made changes - 06/Aug/13 12:18 PM
Field Original Value New Value
Original Estimate 3 days [ 259200 ]
Remaining Estimate 3 days [ 259200 ]
Pavel Bucek made changes - 06/Aug/13 12:19 PM
Assignee stepan.kopriva [ stepan.kopriva ]
Pavel Bucek added a comment - 06/Aug/13 12:24 PM

Hi,

thanks for your bug report. have you tried to send or receive text or binary message?

From what I see it could be described as "receiving/sending pong/ping messages does not reset session idle timeout". Is that correct?

Thanks,
Pavel


martinandersson.com added a comment - 06/Aug/13 12:30 PM

I have tried to send text. So text and ping/pong is affected. Haven't tried binary though.


stepan.kopriva made changes - 09/Aug/13 07:21 AM
Status Open [ 1 ] Resolved [ 5 ]
Fix Version/s 1.3 [ 16600 ]
Resolution Fixed [ 1 ]