Yes, I do mean servlet filters. I really don't mean to be rehashing old arguments, but the 'outside of a web environment' argument seems like a bit of a red herring to me.
Lets take a few examples where the use of interceptors is mentioned... - Hibernate sessions: A filter could start and close the session. It has nothign to do with webwork, and tieing them together seems like strong coupling for no good reason (that I can see). Same for TX, really. You want to use it in your swing client? Great, just open and close your session before calling the action. In fact, since it's a persistent client, you'd open the session once, then close it when user closes the app, rather than constant open/close on every action. - Authentication: Again, a filter works wonderfully (as it does currently). Regarding out of web usage, method of auth is more often than not likely to be fairly different. Resource requests are also different, so really, you won't be able to 'drop in' your code without adding some awareness/abstraction in it that lets it handle the appclient case gracefully. With 'non-web' in general, people seem to forget that if your actions talk to a db and suchlike, then you now find yourself having to add a db connection pooling mechanism (since xwork is request/response, very much unlike how things are done normally in swing/appclient frontends). There are also a whole host of other paradigm shifts when moving to appclients, and the focus on it in xwork seems to be (perhaps wrongly) to ignore those, and focus on the final 1% of the task, which is to remove serlvet/explicit web stuff. I agree with the pain in the ass to define. So are we saying that the main advantage of interceptors is that they provide a richer urlpattern? Quoting Mike Cannon-Brookes <[EMAIL PROTECTED]>: > Hani, > > Do you mean servlet filters? In which case - surely they don't work at all > outside a web environment? > > And the other problem is that servlet filters are not applied directly to a > specific action / group of actions, they are URL pattern based? (which is a > royal pain in the ass to define!) > > Mike > On 13/1/03 10:45 PM, "Hani Suleiman" ([EMAIL PROTECTED]) penned the words: > > > Are interceptors really that different from filters? If they are very > > different, then I'm missing something and you can ignore the rest of this > > email... > > > > However, if they aren't that different, then I believe that they are few > cases > > where a interceptor would be required instead of a filter. Filters should > also > > be encouraged as they have a far better chance of working if you moved > outside > > of a web environment. > > > > From hearing examples bandied about here, some people seem to think of > > interceptors for stuff like security and login, which IMHO is an abuse of > > them. > > Thoughts? > > > > Hani > > > > > > > > > > > > ------------------------------------------------------- > > This SF.NET email is sponsored by: FREE SSL Guide from Thawte > > are you planning your Web Server Security? Click here to get a FREE > > Thawte SSL guide and find the answers to all your SSL security issues. > > http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0026en > > _______________________________________________ > > Opensymphony-webwork mailing list > > [EMAIL PROTECTED] > > https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork > > > > ------------------------------------------------------- > This SF.NET email is sponsored by: FREE SSL Guide from Thawte > are you planning your Web Server Security? Click here to get a FREE > Thawte SSL guide and find the answers to all your SSL security issues. > http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0026en > _______________________________________________ > Opensymphony-webwork mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork > > ------------------------------------------------------- This SF.NET email is sponsored by: FREE SSL Guide from Thawte are you planning your Web Server Security? Click here to get a FREE Thawte SSL guide and find the answers to all your SSL security issues. http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0026en _______________________________________________ Opensymphony-webwork mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork