tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Farid C <do_not_reply_ple...@yahoo.fr>
Subject RE: Tomcat/Web application conf: status code 404 versus status code 302 + 200
Date Fri, 09 Apr 2004 17:48:40 GMT
Good evening

I want that it serve the /index.jsp file
when a page is not found
but as I described (see below)
I need a 404 status code in the http response header.

thank you for any advise
F

 --- Daniel Huang <danihuan@cisco.com> a écrit : > If
you don't want tomcat to serve your /index.jsp
> when 404 is encountered,
> just remove the <error-page> config from your
> web.xml.
> 
> Is this what you are asking? Not sure I got your
> question right.
> 
> Regards,
> Daniel
> 
> -----Original Message-----
> From: Farid C [mailto:do_not_reply_please@yahoo.fr]
> Sent: Friday, April 09, 2004 6:25 AM
> To: tomcat-user@jakarta.apache.org
> Subject: Tomcat/Web application conf: status code
> 404 versus status code 302
> + 200
> 
> Good Morning
> 
> We use Tomcat 5.0.18 with 2 instances:
> 
> A)
> For the both instances, we catch the 404 status code
> returned in the http response to display an index
> page.
> 
> file web.xml:
> <error-page>
> <error-code>404</error-code>
> <location>/index.jsp</location>
> </error-page>
> 
> B)
> If a web browser asks a non existing url, as
> expected
> the 2 tomcat instances return the index.jsp page
> but according to the tomcat log the behaviour
> is not the same:
> there is one http request for one tomcat instance
> (with  a status code 404) against 2 http requests
> for
> the other instance (status code 302 then status code
> 200).
> 
> First tomcat instance log:
> 
> 199.99.99.99 - - [09/Apr/2004:14:27:21 +0100] "GET
> /appli/notExistingPage HTTP/1.1" 404 - 6008
> 
> Second tomcat instance log:
> 
> 199.99.99.99 - - [09/Apr/2004:14:27:21 +0100] "GET
> /appli/notExistingPage HTTP/1.1" 302 -
> 
> 199.99.99.99 - - [09/Apr/2004:14:27:21 +0100] "GET
> /appli/index.jsp HTTP/1.1" 200 5900
> 
> I failed to find in the configuration why the  2
> tomcat instances behave differently for our web
> application.
> 
> It is critical for us to have only one http request
> with the error code 404:
> any idea how can I control this behaviour in the
> tomcat or web application configuration ?
> 
> Any help will be appreciated
> 
> thank you
> F



	

	
		
Yahoo! Mail : votre e-mail personnel et gratuit qui vous suit partout ! 
Créez votre Yahoo! Mail sur http://fr.benefits.yahoo.com/

Dialoguez en direct avec vos amis grâce à Yahoo! Messenger !Téléchargez Yahoo! Messenger
sur http://fr.messenger.yahoo.com

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


Mime
View raw message