You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Pascal Gauthier <pg...@le-son666.com> on 2005/04/06 19:08:30 UTC

Custom 404 page when a webapp is stopped by the manager

Hi,

we have a tomcat webapp that needs to be down if we are doing a maintenance to the database. The manager seems to be the perfect solution to make the application unavailable but we found out that the 404 error-page cannot be customized.

Even if we modified the default web.xml (in conf/) to add the error-page 404,  it doesn't seems to be resolved when the context is stopped.

If I type an URL that doesn't exists, that doesn't map to any context, I get the right error page. But if it match a context path of a webapp that is stopped, I have the Tomcat default error page. Is there a way to fix this?

Are we the only one trying to have a custom error page when the webapp is down? 

thanks in advance
pascal.



---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Custom 404 page when a webapp is stopped by the manager

Posted by Lionel Farbos <li...@free.fr>.
Hi,

If you use apache and mod_jk, an issue could be :
when you stop your Context, you change your JkMount towards a custom Tomcat Context that display your desired error-page.

If you use a Tomcat standalone, I don't kown how to ... :-(
Regards.

On Wed, 6 Apr 2005 13:08:30 -0400
"Pascal Gauthier" <pg...@le-son666.com> wrote:

> Hi,
> 
> we have a tomcat webapp that needs to be down if we are doing a maintenance to the database. The manager seems to be the perfect solution to make the application unavailable but we found out that the 404 error-page cannot be customized.
> 
> Even if we modified the default web.xml (in conf/) to add the error-page 404,  it doesn't seems to be resolved when the context is stopped.
> 
> If I type an URL that doesn't exists, that doesn't map to any context, I get the right error page. But if it match a context path of a webapp that is stopped, I have the Tomcat default error page. Is there a way to fix this?
> 
> Are we the only one trying to have a custom error page when the webapp is down? 
> 
> thanks in advance
> pascal.
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org