users@jersey.java.net

Re: [Jersey] JerseyFilter and WebPageContentRegex

From: James Strachan <james.strachan_at_gmail.com>
Date: Thu, 11 Mar 2010 16:01:00 +0000

On 11 March 2010 12:07, Paul Sandoz <Paul.Sandoz_at_sun.com> wrote:
> Hi James,
>
> What if we could detect if a 404 would be returned, and if so proceed to the
> next filter in the chain?

Yeah, that sounds good.


> This may result in the execution of some user code e.g. execution of
> sub-resource location methods could be a definite possibility. But is that
> an issue? and for the case you present it should work really well.
>
> Off the top of my head there are three types of 404 we could detect:
>
> 1) No match of a URI path;
>
> 2) A query or path param conversion failure; and
>
> 3) An application return an 404, by an exception or a direct response.
>
> Maybe these cases could be configuration options?

Yeah. 1) is the biggie really; I'm happy for 2 & 3 to not pass through
to the servlet container (though its not a biggie if they do)

-- 
James
-------
http://macstrac.blogspot.com/
Open Source Integration
http://fusesource.com/