HttpServletRequest request =((ServletRequestAttributes) RequestContextHolder.getRequestAttributes()) .getRequest() ; HttpSession session=request .getSession() ;//达到session对象