Re: How to suppress error page for a response with only the status code set

2008-03-19 Thread Martin Grotzke
On Tue, 2008-03-18 at 16:42 -0700, Hassan Schroeder wrote: On Tue, Mar 18, 2008 at 4:28 PM, Martin Grotzke [EMAIL PROTECTED] wrote: Only for the REST api (mapped to a specific path/url-pattern) we do not want to return these error pages but only codes. So write dynamic error pages

Re: How to suppress error page for a response with only the status code set

2008-03-19 Thread Martin Grotzke
Hi, just to check if this would be an option: is it possible to tell tomcat not to render its error pages? Of course one configure an empty file as error page, but this would have to be done for *all* error codes AFAICS. Thanx cheers, Martin On Tue, 2008-03-18 at 17:15 -0400, Christopher

How to suppress error page for a response with only the status code set

2008-03-18 Thread Martin Grotzke
Hi, we have a web application running in tomcat that returns error pages for status codes like e.g. 404 - absolutely fine. In the same servlet context we provide a RESTful API (using jersey [1]), that in most of the cases returns xml. In some cases responses with only the error code set (e.g.

Re: How to suppress error page for a response with only the status code set

2008-03-18 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Martin, Martin Grotzke wrote: | Is there a way not to return error pages in these cases? You could set an error-page in web.xml that produces no output for these status codes. Something like: error-page ~ error-code400/error-code ~

Re: How to suppress error page for a response with only the status code set

2008-03-18 Thread Martin Grotzke
Hi, On Tue, 2008-03-18 at 17:15 -0400, Christopher Schultz wrote: You could set an error-page in web.xml that produces no output for these status codes. the rest of the application serves pages visited by humans - for them we want to display error pages. (Sorry, I didn't point this out) Only

Re: How to suppress error page for a response with only the status code set

2008-03-18 Thread Hassan Schroeder
On Tue, Mar 18, 2008 at 4:28 PM, Martin Grotzke [EMAIL PROTECTED] wrote: Only for the REST api (mapped to a specific path/url-pattern) we do not want to return these error pages but only codes. So write dynamic error pages that return the appropriate content (or lack thereof) based on the