Some example of filters that I use:
Check that there is a logged in user; redirect to login if not.Add no-cache headers to the response.Ensure that a Hibernate session is active.
That way, each and every
servlet or
JSP doesn't need to be concerned with these things that have to happen in every request.