Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Change 404 error page when deploy with Jetty inside Equinox (How to add a custom error page to a web application)
Change 404 error page when deploy with Jetty inside Equinox [message #900879] Wed, 08 August 2012 19:26 Go to next message
George R Malary is currently offline George R Malary
Messages: 36
Registered: March 2012
Location: New Jersey
Member
I have seen how to do this when depoloying a WAR file:

<servlet-mapping>
<servlet-name>equinoxbridgeservlet</servlet-name>
<url-pattern>/app/*</url-pattern>
</servlet-mapping>

<error-page>
<error-code>404</error-code>
<location>/error404.html</location>
</error-page>


How can we do something similar when deploying the web server inside the OSGi runtime (Equinox + Jetty + RAP + your app). I am deploying into a Virgo-tomcat server. Can I configure the custom error page in the config.ini there?
Re: Change 404 error page when deploy with Jetty inside Equinox [message #901566 is a reply to message #900879] Mon, 13 August 2012 12:56 Go to previous messageGo to next message
Rüdiger Herrmann is currently offline Rüdiger Herrmann
Messages: 565
Registered: July 2009
Senior Member
George,

the plain HttpServer has no support for web.xml, hence custom error
pages won't work.
Virgo however may have support for this. You should ask this question on
the Virgo forum.

Regards,
Rüdiger


On 08.08.2012 21:26, George R Malary wrote:
> I have seen how to do this when depoloying a WAR file:
>
> <servlet-mapping>
> <servlet-name>equinoxbridgeservlet</servlet-name>
> <url-pattern>/app/*</url-pattern>
> </servlet-mapping>
>
> <error-page>
> <error-code>404</error-code>
> <location>/error404.html</location>
> </error-page>
>
>
> How can we do something similar when deploying the web server inside the
> OSGi runtime (Equinox + Jetty + RAP + your app). I am deploying into a
> Virgo-tomcat server. Can I configure the custom error page in the
> config.ini there?--
Rüdiger Herrmann
http://codeaffine.com
Re: Change 404 error page when deploy with Jetty inside Equinox [message #902440 is a reply to message #901566] Fri, 17 August 2012 15:09 Go to previous messageGo to next message
George R Malary is currently offline George R Malary
Messages: 36
Registered: March 2012
Location: New Jersey
Member
Thanks for the reply. Will look into another way to configure this. Regards, GEorge
Re: Change 404 error page when deploy with Jetty inside Equinox [message #907137 is a reply to message #902440] Mon, 03 September 2012 11:09 Go to previous message
Markus Knauer is currently offline Markus Knauer
Messages: 109
Registered: July 2009
Senior Member

You could try to replace the http service that comes with Equinox/Jetty with the implementation from

http://team.ops4j.org/wiki/display/paxweb/Pax+Web

They are providing an extended http service that allows the registration of customized error pages and other insteresting things:

http://team.ops4j.org/wiki/display/paxweb/Error+Pages

Maybe this helps to solve your problem...


--
Markus Knauer

Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/

Professional services for RAP and RCP?
http://eclipsesource.com/services/rap/
Previous Topic:Tycho build of feature including RAP
Next Topic:Authentication for WebServices (Glassfish)
Goto Forum:
  


Current Time: Tue Oct 21 16:52:49 GMT 2014

Powered by FUDForum. Page generated in 0.10375 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software