Java Spring Session not persist between requests

后端 未结 2 1369
南方客
南方客 2021-01-26 10:56

I have this controller

@Controller
@RequestMapping(value = \"/login\")
public class Login{

    @RequestMapping
    public ModelAndView mainPage(HttpServletReque         


        
2条回答
  •  生来不讨喜
    2021-01-26 11:24

    Are you using spring security? May be you can set http.sessionManagement().sessionCreationPolicy(SessionCreationPolicy.NEVER) if you are managing sessions by yourself

    Reference: https://www.baeldung.com/spring-security-session

提交回复
热议问题