| Re: [jetty-users] Jetty does not remove timed-out session, if the session was replaced in runtime |
Hi,n the application, we use to switch sessions once the user mode is changed.
So basically we have something like this:
request.getSession(false).invalidate();
request.getSession(true);Now happens the problem: after timeout, the session is not removed. After debugging some internal code, I found out that in
org.eclipse.jetty.server.session.AbstractSession.timeout()the session is not removed if_requests > 0. And the_requestsis greater then zero, since inorg.eclipse.jetty.server.session.SessionHandler.doScope(String, Request, HttpServletRequest, HttpServletResponse)thecomplete()runs on theaccesssession is increased and the same session is decreased, even if during the invocation the actual session was replaced!Did anyone experience the same problem and managed to solve it?
Thanks,
Michael
P.S. This question was also posted at Stackverflow at http://stackoverflow.com/q/10300283/547779