>>>>> Steinar Bang <[email protected]>:
[snip!]
> Is there any guarantee that activate() won't be called until after
> init(FilterConfig) has been called?
Nope. When activate() was called, getFilterConfig() returned null:
@Activate
public void activate() {
WebEnvironment env =
WebUtils.getRequiredWebEnvironment(getFilterConfig().getServletContext());
setSecurityManager(env.getWebSecurityManager());
FilterChainResolver resolver = env.getFilterChainResolver();
if (resolver != null) {
setFilterChainResolver(resolver);
}
}
I guess one way to do this would be to create a @Component that
implements the Filter interface and wraps a ShiroFilter. Ie. it creates
a ShiroFilter instance and calls init(FilterConfig) on the ShiroFilter
and then does its own thing.
It should work... but it feels cumbersome...
--
--
------------------
OPS4J - http://www.ops4j.org - [email protected]
---
You received this message because you are subscribed to the Google Groups
"OPS4J" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.