• Post Reply Bookmark Topic Watch Topic
  • New Topic

servlet error

 
Jay Richards
Ranch Hand
Posts: 58
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i have created an app in tomcat webapps directly. it's working with *.jsp. but it seems i can't call a any of my servlet.
http://127.0.0.1:8080/catalog/servlet/ShowImage
it returns a "HTTP Status 404"
description The requested resource (/catalog/servlet/ShowImage) is not available.
is there still any special configuration that i should make?
thanks
 
zhao feng
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
is there a WEB-INF file in that DIR
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13078
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That /servlet/ usage usually requires that the "invoker" servlet be turned on for that application. See the tomcat-home/conf/web.xml file - search for "invoker"
Bill
 
Jay Richards
Ranch Hand
Posts: 58
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks.
i have to put invoker setting in the web.xml of my app.
just wondering why resin does not require it.
thanks again for the help...
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13078
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That gets us into the history of Servlets - the first API, servers and books made extensive use of the /servlet/ convention.
However, as the API evolved, Sun wanted to make servlet/JSP applications (and J2EE applications) very standardized, easily "plugged in" to servers, and transparent (not obviously servlets). Not using the /servlet/ convention helps with all three.
Starting with Tomcat 4 (as I recall) the invoker was no longer on by default in order to help this transition.
Bil
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!