injecting `sessionScoped` `managedBean` doesn't work

134 Views Asked by At

I have a sessionScoped managedBean called UserManager, when I try to print #{UserManager.loggedIn} in the view, It work, but in my servlet-filter the injection of this managedBean doesn't work.

I tried to inject it like this:

@ManagedProperty(value="#{userManager}")
private UserManager userManager;

And in userManager I have null pointer.

0

There are 0 best solutions below