I have a JSF Mojarra 2.3.9.SP02 application and a couple of beans there. One of the beans looks as follows:
@Named("unterlagenBean")
@javax.faces.view.ViewScoped
public class UnterlagenBean extends KauferBaseBean implements Serializable {
// code here
}
The parent class looks as follows:
public abstract class KauferBaseBean {
@Inject
@javax.faces.bean.ManagedProperty(value = "#{kauferSessionContainer}")
private KauferSessionContainer kauferSessionContainer;
}
And the KauferSessionContainer looks as follows:
@Named("kauferSessionContainer")
@SessionScoped
public class KauferSessionContainer extends AveSessionContainer {
}
Now, I have a servlet, from which I want to access the KauferSessionContainer, if there is a HttpSession, and if the KauferSessionContainer is in this session.
How can I do this? Simply trying
request.getSession(false).getAttribute("kauferSessionContainer")
delivers null