I have a filter setup where I set a session variable like so:HttpSession session = httpServletRequest.getSession();
session.setAttribute("myLastName", "some last name");How would I access this value inside of an extension that I write? I tried:String lastName = (String) RequestContextHolder.currentRequestAttributes().getAttribute("myLastName", RequestAttributes.SCOPE_SESSION);But I get the following error thrown when that line is executed:No thread-bound request found: Are you referring to request attributes outside of an actual web request, or processing a request outside of the originally receiving thread? If you are actually operating within a web request and still receive this message, your code is probably running outside of DispatcherServlet/DispatcherPortlet: In this case, use RequestContextListener or RequestContextFilter to expose the current request.
Does anyone know how to access session variables created inside of filters?thanks,