You are calling the method HttpServletResponse.sendRedirect(String path) and you want to make sure that the user continues in the same session. How do you that?
1) By calling the method with an absolute path as the argument
2) By enconding the path with HttpServletResponse.endcodeURL method
3) By enconding the path with HttpServletResponse.endcodeRedirectURL method
4) If you use sendRedirect the session is lost.