20060921 Thursday September 21, 2006

TSS runs on Tomcat? Looks like TheServerSide.com runs on Tomcat - or at least that's what their 404 page says. I don't know which is better - TSS's 404, Javablog's 404 (blank page) or JavaLobby's. It's hard to believe that major sites like these don't have better 404 pages.

For those of you who want to add a 404 page to your Java-based webapp, it's as simple as adding the following to your web.xml:

    <error-page>
        <error-code>404</error-code>
        <location>/404.jsp</location>
    </error-page>

Props to InfoQ for implementing a 404 page, even if it is rather useless. Posted in Java at Sep 21 2006, 12:28:22 PM MDT 10 Comments

Comments:

Yesterday I had a wonderfull stacktrace on infoq.com site. It runs on tomcat 5.5.17 with webwork and Spring :-)

Posted by G. on September 21, 2006 at 01:50 PM MDT #

No one pay us for appropriate Error Messages. That´s the way we walk ;)

Posted by Roman on September 21, 2006 at 04:12 PM MDT #

TSS is running on JBoss4:)

Posted by Tony Xu on September 21, 2006 at 08:47 PM MDT #

I think TSS is also running on Tapestry. (at least it used to)

Posted by Jesse Kuhnert on September 21, 2006 at 09:37 PM MDT #

How would you configure an all-encompasing error message? Your example would work fine if someone tried to access http://site/existingContext/foo.jsp but what if they try to access http://site/nonExistingContext?

Posted by KenLin on September 22, 2006 at 08:11 AM MDT #

http://raibledesigns.com/page/rd/foo

Posted by Sanjiv Jivan on September 22, 2006 at 08:49 PM MDT #

http://support.microsoft.com/default.aspx?scid=KB;en-us;q218155 dont forget to make your error messages more than 512 bytes else they won't be shown in IE. Arghh!

Posted by Sam Hough on September 23, 2006 at 03:28 AM MDT #

Good one Sanjiv, I thought I was covered but it looks like Roller has some issues. It looks like it may be fixed in 3.0.

Posted by Matt Raible on September 23, 2006 at 09:38 AM MDT #

http://www.theserverside.com/tt/articles/article.tss?l=TSSTapestry

Posted by Alexandre Jacques on September 24, 2006 at 08:09 AM MDT #

A List Apart (ALA) published an excellent article about "The Perfect 404" months ago, promoting the design of a more "intelligent" 404. I recommend having a read, that's certainly interesting: http://www.alistapart.com/articles/perfect404/

Posted by Sebastien on September 28, 2006 at 08:31 AM MDT #

Post a Comment:
  • HTML Syntax: Allowed