File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes 404 error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "404 error" Watch "404 error" New topic

404 error

shubhangi phadke

Joined: Feb 05, 2007
Posts: 2

I am getting request resource not avialbe when i access the servlet class which is alredy present in correct path as page30-31 in HeadFirst jsp&servlets..

Created the correct directory structure under webapps/ch1 : WEB-INF and classes put web.xml and class file correctly..

able to access servlet-examples ans jsp-examples but not the below one


My web.xml is

<web-app xmlns=""
xsi:schemaLocation=" web-app_2.4.xsd"

<servlet-name>Chapter1 Servlet</servlet-name>

<servlet-name>Chapter1 Servlet</servlet-name>

Can anyone help me out in solving this..
Christophe Verré

Joined: Nov 24, 2005
Posts: 14687

You should put your servlets in packages, to avoid unpredictable results.

[My Blog]
All roads lead to JavaRanch
S Kapoor

Joined: Mar 31, 2006
Posts: 20
Confirm that this is the name and location of the servlet class:

shubhangi phadke

Joined: Feb 05, 2007
Posts: 2
hey thanks ,i got the result
It is sorta covered in the JavaRanch Style Guide.
subject: 404 error
Similar Threads
404 Error
First Example Of HFServlets & JSP Not Working
I am not able to Run Head First servlet example
new to tomcat
Cannot deploy servlet(resource not available)