Re: [Stripes-users] retrieve StripesFilter configuration outside of an Stripes request

2016-08-02 Thread VANKEISBELCK Remi
Yes ServletContextAware suffers the same problem. I think the best option right now, with the current codebase, is to subclass StripesFilter and do whatever you need in init(). This way you are quite sure the filter is there :P A more "Stripey" way to handle this would be a proper initializer

Re: [Stripes-users] retrieve StripesFilter configuration outside of an Stripes request

2016-08-02 Thread Juan Pablo Santos Rodríguez
Hi Rémi, indeed the init sequence problem is there, but the mbean is going to be called much fewer times than a regular intercepted URL. It doesn't matter too much if the mbean returns an empty map (people using the mbean would know the application is starting). Besides, at the time the MBean is

Re: [Stripes-users] retrieve StripesFilter configuration outside of an Stripes request

2016-08-02 Thread VANKEISBELCK Remi
Hi again Juan Pablo, Cool ! Glad to know it works. Indeed, you still have a "init sequence" problem, but I guess that those url bindings are irrelevant until the filter is up. I mean, you get the actual result by invoking the MBean : it returns an empty list of bindings if the filter is not

Re: [Stripes-users] retrieve StripesFilter configuration outside of an Stripes request

2016-08-02 Thread Juan Pablo Santos Rodríguez
Hi Rémi, thanks for the tip! :-) Although my JMX MBean doesn't have access to the servlet context, it's also a Spring managed bean, so I've also made it ServletContextAware, which solves the access to the servletContext from the MBean. At the time of servletContext injection, the Stripes Filter

Re: [Stripes-users] retrieve StripesFilter configuration outside of an Stripes request

2016-08-01 Thread VANKEISBELCK Remi
Hi again, Ok, seems too complicated. Another way maybe : use the StripesFilter instance that is bound to the ServletContext. In net.sourceforge.stripes.controller.StripesFilter#init : this.servletContext.setAttribute(StripesFilter.class.getName(), this); So I guess that you can retrieve the

Re: [Stripes-users] retrieve StripesFilter configuration outside of an Stripes request

2016-08-01 Thread Juan Pablo Santos Rodríguez
Hi Remi, quite there, but still not sure if there is a better way to do this. ConfigurableComponent is used on two separate places: - to instantiate core parts of Stripes (i.e. object factory, action bean resolver, property binder, context factory, etc.). Stripes only allows to have on of each

Re: [Stripes-users] retrieve StripesFilter configuration outside of an Stripes request

2016-07-28 Thread VANKEISBELCK Remi
Hi Juan Pablo, Maybe keep the configuration it as a static field of a @ConfigurableComponent ? Note that it'll work only if you have one config. Stripes config allows to do lots of fancy stuff that I personally never used, but who knows, that door is open :P Cheers Rémi 2016-07-28 14:27

[Stripes-users] retrieve StripesFilter configuration outside of an Stripes request

2016-07-28 Thread Juan Pablo Santos Rodríguez
Hi, we're currently developing some MBeans for some administrative tasks and we would like to expose all registered ActionBeans URLs through JMX. Obtaining them is easy, if you have a request routed through StripesFilter: Map< String, Object > stripesUrlBindings() { final Map<