• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Liutauras Vilda
  • Campbell Ritchie
  • Tim Cooke
  • Bear Bibeault
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Knute Snortum
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Ganesh Patekar
  • Stephan van Hulst
  • Pete Letkeman
  • Carey Brown
Bartenders:
  • Tim Holloway
  • Ron McLeod
  • Vijitha Kumara

Mistakenly changed web.xml  RSS feed

 
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I mistakenly changed my web.xml, and now when i just try to load up a simple jsp through http://localhost:8080/cmt3082/Register.jsp, i get the error
description The requested resource () is not available.

My folder hierachy is like so:
C:
cmt3082 - jsp files
WEB-INF
classes - servlets
Olympics - java classes

My web.xml is one i got from uni, quite long. What could i have changed which will stop me from loading up a simple jsp from the cmt3082 folder?

web.xml

 
Author and ninkuma
Marshal
Posts: 66806
168
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dang, my average web.xml is under 100 lines. I'd trim out all the useless crap if I were you.

Check the logs. It's likely that the web app is never starting due to some error. If you are using Tomcat, check the Manager application to see if it's running or not.
 
Nick Price
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is the first part of my error log, i have no idea what it means.


I am using Tomcat, but i dont know what the username and password is for the manager application.
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 66806
168
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You set it in tomcat-users.xml.

 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 66806
168
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It looks as if Tomcat is quite unhappy with your web.xml.
 
Nick Price
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Let me ask you a quick question so i understand this better. When you download and install tomcat, you get a web.xml off them. Now say i create my own internet application using jsp, servlets and java, but i am saving this application in my own folder rather than the Tomcat's web apps folder. SHould i be creating a new web.xml and placing it in my new folder, or should i be making changes to the web.xml in the Tomcat folder?
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 66806
168
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Each web app has its own.
 
Ranch Hand
Posts: 2458
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Bear Bibeault wrote:Dang, my average web.xml is under 100 lines. I'd trim out all the useless crap if I were you.

ThatĀ“s the web.xml of the application server, not of the web application.
 
Bauke Scholtz
Ranch Hand
Posts: 2458
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Nick Price wrote:Let me ask you a quick question so i understand this better. When you download and install tomcat, you get a web.xml off them. Now say i create my own internet application using jsp, servlets and java, but i am saving this application in my own folder rather than the Tomcat's web apps folder. SHould i be creating a new web.xml and placing it in my new folder, or should i be making changes to the web.xml in the Tomcat folder?

you should never ever need to change the appserverĀ“s configuration files.

Imagine what would happen when you decide to change/upgrade the appserver, distribute your app and/or wanted to use a public hosting provider.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!