-
1. Re: can't run my hello servlet on jboss
dudoes Aug 6, 2002 8:53 AM (in response to proceed99)I think you should change
"<servlet-mapping>
<servlet-name>helloServlet</servlet-name>
<url-pattern>/hello.html</url-pattern>
</servlet-mapping>
"
to
"
<servlet-mapping>
<servlet-name>helloServlet</servlet-name>
<url-pattern>/hello</url-pattern>
</servlet-mapping>
"
then
modify ACTION = hello in form
you can test it. -
2. Re: can't run my hello servlet on jboss
proceed99 Aug 6, 2002 11:07 PM (in response to proceed99)Still can't work,
HTTP Status 404 - /hello
The requested resource (/hello) is not available.
Seems like I don't have the proper path to the hello servlet.
regards, -
3. Re: can't run my hello servlet on jboss
dudoes Aug 7, 2002 12:31 AM (in response to proceed99)Jboss3 is a EJB container, not a jsp/servlet Engine.
Tomcat4 is jsp/servlet Engine.
you use Jboss3 to test the Hello rather than Jboss3/tomcat4 bundle? -
4. Re: can't run my hello servlet on jboss
proceed99 Aug 7, 2002 6:36 AM (in response to proceed99)I am using Jboss 3 with tomcat 4 bundle.
As you can see, I am trying to test to a very simple hello servlet. But the hello page doesn't come up in the browser.
Please help, instruction needed. -
5. Re: can't run my hello servlet on jboss
tbfmicke Aug 7, 2002 8:40 AM (in response to proceed99)Since the servlet is in hello.war, to reach the hello servlet you need to write:
http://localhost:8080/hello/hello
The first "hello" is for the webapp, the second is for the servlet.
Regards -
6. Re: can't run my hello servlet on jboss
dudoes Aug 7, 2002 1:15 PM (in response to proceed99)OK!
you should call the URL:
===================
http://localhost:8080/hello/hello.html
=====================
I test your Hello in my computer, Wonderful!
by the way, I support:
1. according thd java spec, first char of class name should is uppercase
2. servlet should answer both GET and POST method type, only add:
-------------------------------
public void doPost(HttpServletRequest request,HttpServletResponse response)throws ServletException, IOException
{
doGet(request, response);
}
------------------------------------
3. do had better, move "destroy()" to the end of Servlet. -
7. Re: can't run my hello servlet on jboss
proceed99 Aug 8, 2002 12:00 AM (in response to proceed99)I don't know why I can't see my hello servlet on the browser deployed as a web module hello.war
But it works fine when I deployed as hello.ear
Strange for me, did i miss anything in the jboss configuration?? -
8. Re: can't run my hello servlet on jboss
dudoes Aug 8, 2002 2:48 AM (in response to proceed99)Hi,
Maybe you should put your Hello in a Package,you only add:
--------------
package mytest;
-----------------
at top of hello.java
and change web.xml:
-----------------
<?xml version="1.0" encoding="UTF-8"?>
<!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-name>helloServlet</servlet-name>
<servlet-class>mytest.hello</servlet-class>
<servlet-mapping>
<servlet-name>helloServlet</servlet-name>
<url-pattern>/hello.html</url-pattern>
</servlet-mapping>
<session-config>
<session-timeout>30</session-timeout>
</session-config>
</web-app>
----------------------- -
9. Re: can't run my hello servlet on jboss
proceed99 Aug 8, 2002 11:18 PM (in response to proceed99)I try to package the java file as you mentioned, but didn't work for me. Still can't not deploy as war file, but ok for ear file.
Do I need to setup web server to make it work? -
10. Re: can't run my hello servlet on jboss
ttimm Aug 12, 2002 10:07 AM (in response to proceed99)I have the same problem. As described above the example works fine when the war is placed in a EAR file. When placing the war file in the default deploy dir, JBoss reports an [Engine] internal error no Web.xml found, as if it was unable to read the web.xml file.
If anyone knows the answer please let us know. Seems strange to me that it works just by placing the same war file in an EAR file. -
11. Re: can't run my hello servlet on jboss
cdkcdk Aug 12, 2002 10:50 AM (in response to proceed99)I just tried to put your hello.war file and jboss just seems to do nothing !!
I'm still stuck trying to deploy web apps with jboss...
I need help too... -
12. Re: can't run my hello servlet on jboss
dudoes Aug 16, 2002 2:06 PM (in response to proceed99)Hi,folks!
Plz use Jboss3.0.1RC1/Tomcat4.0.4, I deploy Hello to it.
all is OK! -
13. Re: can't run my hello servlet on jboss
rsie Aug 19, 2002 9:37 PM (in response to proceed99)Could you please tell me where to get this distribution?
thanks -
14. Re: can't run my hello servlet on jboss
dudoes Aug 19, 2002 10:47 PM (in response to proceed99)Search JBOSS.NET,or Jboss3.0.1RC1,Tomcat4 in http://sourceforge.net,you can find it, I can not reach sourceforge.net now