Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

The requested resource (/SecondServlet/) is not available?

 
Sapumal Bandara
Ranch Hand
Posts: 31
Android Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Guys please help me with this. I am new to servlets. I created a simple java servlet ("SecondServlet ") using Eclipse IDE and JBoss AS. When I ran it on the AS it says: "The requested resource (/SecondServlet/) is not available".. Any help is much appriciated.

Thank you.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64851
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
See the ServletsFaq for a checklist of things to check.
 
Sapumal Bandara
Ranch Hand
Posts: 31
Android Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Bear Bibeault, Thanks for the direction .

Regards,
Sapumal
 
J. Kevin Robbins
Bartender
Posts: 1759
19
Chrome Firefox Browser jQuery Linux MySQL Database Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Be sure to check for package declarations on your servlet classes. If you still can't find the problem, post your web.xml file here.
 
Sapumal Bandara
Ranch Hand
Posts: 31
Android Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Kevin, below is my web.xml file. Can you explain a bit what you mean by "Check package declaration.."? Thanks.


 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64851
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you looked through the list? I can already see that your servlet is not in a non-default package.
 
Sapumal Bandara
Ranch Hand
Posts: 31
Android Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Bear Bibeault, Previously I didn't get what you said. I created a new package and put my servlet in it. The thing is that I have to create the servlet by right clicking on the WebContent folder.. Finally all together it worked. Thank you all.

Regards,
Sapumal.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic