What are the contents of the testservlet.war directory and of the testservlet.war/WEB-INF/web.xml file.
root-dir - testservlet.war
dir - WEB-INF
| dir - classes
| dir - test
| - TestServlet.class
| - TestServlet.java
And contents of web.xml are:
<?xml version="1.0" encoding="ISO-8859-1"?>
I am just testing a HTTP Servlet
I hope this helps out.
You need to either add a welcome-file-list to your web.xml:
<welcome-file-list> <welcome-file>TestServlet</welcome-file> </welcome-file-list>
or use the following url:
Worked like a charm. Thank you. Do you have any idea why this wasn't required for Tomcat configuration? Is it because of a different root context?
Actually, I am surpRised that it worked under Tomcat, you should have seen the directory listing there also. Or did you, by any chance, place the testservlet directory under ROOT?
Ok. My goodness. I feel like a dope. Actually, I was actually accessing the servlet via: http://localhost/testservlet/TestServlet, under Tomcat
when I migrated to JBoss I typed the servlet mapping in all lowercase when it should have been in Pascal Case. So, I go a 404 error and I thought it was the wrong URL or the context was incorrect.
Sorry, for the trouble. I'm just beginning with ejb, servlets and jsp's and I migrating to JBoss since I didn't see anything that said Tomcat is a container for EJB's.