RAP application hangs after 3 minutes inactivity [message #1861547] |
Wed, 18 October 2023 11:07 |
|
We are in the process of upgrading from RAP 3.12 to 3.26 and notice what appears to be a change in behaviour with session life.
If we start a session of an application and wait 3 minutes without any activity, the next activity hangs and never comes back. By 'activity', I mean something like a mouse click on a Button control (any interaction by user with the UI in fact).
We use Server Push, no different compared to 3.12.
In addition, we can optionally initiate a browser-side poll to keep the session alive (by default we don't do this) by putting this JS into the browser:
"setInterval(function(){ rwt.remote.Connection.getInstance().send(); }, " + 1000 * keepAliveCycle + ");"
With this in place, the application does come back, but responses to any user interaction are very very slow and unusable (responses are the same period as specified in the JS above, which we tend to default to 5 seconds). It is as if the RAP runtime has given up with the connection and only responds when forced from the browser. It is like ServerPush no longer exists.
Has something changed between 3.12 and 3.26 with regard to how sessions timeout or keepalive? Sorry, this is a big jump in versions!
I will continue to investigate by simplifying our application to try to identify if there is some specific feature we are using that causes it (there is a lot going on!), but if anyone has any ideas about change in behaviour of RAP that might explain it, then I'd love to know!
Note: same behaviour on all browser types that we've tested, so not specific to one.
Also note: this is with basic OSGi, not using any proper AppServer (haven't tested that).
Thanks, John
---
Just because you can doesn't mean you should
[Updated on: Wed, 18 October 2023 12:10] Report message to a moderator
|
|
|
Re: RAP application hangs after 3 minutes inactivity [message #1861551 is a reply to message #1861547] |
Wed, 18 October 2023 12:32 |
|
Further information, maybe an explanation?
As part of our ServerPush setup we are always calling:
ServerPushManager.getInstance().setRequestCheckInterval(interval);
<interval> is an application-configurable variable we provide, but this defaults to 0 if nothing is specified.
It appears that the change in behaviour in RAP occurs when setRequestCheckInverval(0) is used. Any other value and we have no issues.
Question to the RAP team then... was this a change somewhere between RAP 3.12 and 3.26? No problem either way, as we can ensure that 0 value is never used e.g. minimum allowed coud be 1000ms, but would just like to understand if this was a change in RAP behaviour, or whether we are still looking for another explanation?
Thanks, John
EDIT: seems that we were not setting the interval to 0 after all - it was the absence of setting an interval at all that caused the problem... if we set interval to any positive value then it cures the problem. In RAP 3.12 we never set it at all and it worked ok.
---
Just because you can doesn't mean you should
[Updated on: Wed, 18 October 2023 12:37] Report message to a moderator
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03012 seconds