This week's book giveaway is in the Design forum.
We're giving away four copies of Design for the Mind and have Victor S. Yocco on-line!
See this thread for details.
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Regarding tomcat

 
babu sharath
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi ,
I am using tomcat as webserver . Iam new to serveltes .
I have following questions .

1. In tomcat directory i created deployement directory structure. Then I added one html file. In browser I typed http://localhost:8080/sample/form.html
. And form is appearing in the browser .
Later I added xml file ( as mentioned in HFSJ). Then I typed above same url.
but it is giving following error .
message /sample/form.html
description The requested resource (/sample/form.html) is not available.
Than I added all files ( java class files ) ,than also same error is coming.
My dobut is error in any file ( xml ) will cause the above error .

2. When I change any file ( like java ,xml ) do I need to restart the
tomcat ?

Reghards,
Sharath
 
Martyn Clark
Ranch Hand
Posts: 108
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
You may want to check you web.xml file to make sure you have no typo's in it if there is any the app will not load. Also it is a good idea to restart tomcat if you change the web.xml file or reload the app, because this is what it reads when first loading your application. Are you getting 404 error or 500? If your still having problems post you web.xml code and some one can check it.
 
babu sharath
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
error is 404 error
 
Martyn Clark
Ranch Hand
Posts: 108
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi babu,
Have you checked to make sure the app is running int tomcat?
http://127.0.0.1:8080/manager/html
Just to make sure it is up and running.
 
babu sharath
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
it is working fine ( /manager/html)
xml file i written is :
<web-app xmlns="http://java.sun.com/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
version="2.4">

<servlet>
<servlet-name> select </servlet-name>
<servlet-class>com.example.web.Status </servlet-class>
</servlet>

<servlet-mapping>
<servlet-name> select </servlet-name>
<url-pattern> /Selectname.do </url-pattern>
<servlet-mapping>

</web-app>
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic