06-20-2019, 09:12 AM
(This post was last modified: 06-20-2019, 09:13 AM by Alexandre Machado.)
(06-20-2019, 06:05 AM)ioan Wrote: The problem it seems that has nothing to do with my timeout logic. The stuck sessions appear even without it with and with keepalive=true on all forms.
When the problem appears (this is only once in a while - about once or twice a day - usually at night at low traffic times), no sessions are terminated anymore. Even if I call Terminate, nothing happens. To test, I added this code to my application:
and no sessions were terminated (about 95% of the active sessions when the problem occurs will have the levelstring='' and activeform=nil). To test some more, I'll put the same code without the "if" and try to terminate all active sessions. I'll report back when I have the results.
Hi Ioan,
Maybe I missed something but I thought that you were saying that you weren't using KeepAlive (so I would expect that KeepAlive == False in all forms) and that you had an increasing number of sessions, which is not exactly the same as "sessions not terminating"...
Looking at your code, in theory, IWApplication.ActiveForm = nil should always evaluate to false, unless you are doing something like destroying all forms yourself before the application terminates.