You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Daniel HERLEMONT <dh...@club-internet.fr> on 2000/04/07 16:31:50 UTC

Tomcat newbie - filter

Hello

I envisage to migrate form orion to tomcat. And I am looking for transparent
request filtering capabilities.
Is there any filter servlet capapiblities in Tomcat like in orion.

That is: a servlet that you can declare in config file. A filter servlet is
a servlet where we can overide the service method.
Such filter can be used to implement user defined trace, accesses
authentications, user defined cahes ... in a transparent way from the other
application: we can add, change, remove filters without affecting
application servlets.






Re: Tomcat newbie - filter

Posted by "Craig R. McClanahan" <Cr...@eng.sun.com>.
Daniel HERLEMONT wrote:

> Hello
>
> I envisage to migrate form orion to tomcat. And I am looking for transparent
> request filtering capabilities.
> Is there any filter servlet capapiblities in Tomcat like in orion.
>
> That is: a servlet that you can declare in config file. A filter servlet is
> a servlet where we can overide the service method.
> Such filter can be used to implement user defined trace, accesses
> authentications, user defined cahes ... in a transparent way from the other
> application: we can add, change, remove filters without affecting
> application servlets.
>

Tomcat does not support filters as you described them in Orion -- it has a
somewhat similar concept called interceptors, but they are meant for system
level functions, rather than user level functions.

As of the Servlet Specification version 2.2, filters like this are not in the
standard -- therefore, if you use the facilities provided by a particular
servlet container, you are locking yourself to that container.  There's a
current Java Community Process request going right now (JSR-053) that will
define the next version of the servlet spec, and defining filters in some
standard way is a topic of discussion for the next rev.

Craig McClanahan