Access request Attributes (Set in managed bean before redirect) in Filter by precreating FacesContext?

Two ways: Store in session and let filter remove it from session if necessary. ExternalContext.getSessionMap(). Put("foo", "bar"); There's by the way no need to create FacesContext yourself in a Filter.

Just cast ServletRequest to HttpServletRequest. HttpSession session = ((HttpServletRequest) request).getSession(); String foo = (String) session. GetAttribute("foo"); session.

RemoveAttribute("foo"); Use ExternalContext#redirect() to add it as request parameter. ExternalContext. Redirect("other.

Jsf? Foo=bar"); And then in Filter: String foo = ((HttpServletRequest) request). GetParameter("foo").

Thanks Balus I am taking the first one – Pushkar Feb 7 at 4:47.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions