Sara Bose

Greenhorn
+ Follow
since Jun 25, 2003
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Sara Bose

I do not have any package where classes are. I just have 2 servlet's .class file in
WEB-INF/classes directory. No packages. So my web.xml just lists them both and I am not able to access as I could do in tomcat by http://localhost:8080/<app>/servlet/servletname
I had to put explicit url-mapping to eac of them now. Why?
20 years ago
I used this link to make MySql talk to Jboss.
https://coderanch.com/t/88277/JBoss/JBoss-MySQL-Could-not-dereference
Also see if these links are of use.
http://users.pandora.be/bert.torfs/j2ee.pdf
http://mattkelli.com/tech/mysql/
http://ejbca.sourceforge.net/docs/HOWTO-database.html
They may not be appropriate, but they will help. I do not want to use EJBs. So I just added
mysql-ds.xml file in
%JBOSS_DIST%/server/default/deploy folder and edited it to my MySql setting. For Ejb use, you may have to fix 1 other xml file I guess
20 years ago
Hi
I did try http://localhost:8080/test/TestServlet. It also said the same mapping URI error.
Now I fixed by doing what you said, having a <url-mapping> for all of them. I consider this to be a hack. It works, but this not the way we usually do when we use tomcat seperately right. With just <servlet></servlet> mapping it would work, if the class is in application/classes dir. Why does it not work so with JBoss implementation now?
Thanks
20 years ago
Hi
Please help me on this. This is urgent.
I am using jboss-3.2.1_tomcat-4.1.24 version and I made a simple web application and put the war file in JBOSS\server\default\deploy directory.
WEB-INF\web.xml
WEB-INF\classes\TestServlet
is my directory structure of my war and my web.xml is
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
"http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app>
<servlet>
<servlet-name>TestServlet</servlet-name>
<servlet-class>TestServlet</servlet-class>
</servlet>
</web-app>
If i start the jBoss, I see my test.war being deployed fine. But, if Iaccess it as http://localhost:8080/test/servlet/TestServlet
froma browser, I get a 404 error and jBoss console says
"mapping error for URI /test/servlet/TestServlet"
I then tried adding a servlet-mapping to my web.xml by adding
<servlet-mapping>
<servlet-name>TestServlet</servlet-name>
<url-pattern>/</url-pattern>
</servlet-mapping>
Now, if I access using the URL http://localhost:8080/test/, it goes to the testServlet page. I need to add more serlvlets now. This mapping is not right. Books i read say that without mapping itself, we should be able to access the servlet, but I always get 404 and mapping error of URI. What do i do. Please help me soon.
20 years ago