Programmatically change session timeout
问题 I can logout user after defined time of inactivity. <session-timeout>240</session-timeout> But, is there some way to logout in specified time, or better, for example until 5 minutes of inactivity after specified time.? 回答1: You can change the session timeout by HttpSession#setMaxInactiveInterval() wherein you can specify the desired timeout in seconds. When you want to cover a broad range of requests for this, e.g. all pages in folder /admin or something, then the best place to do this is to