-
1. Re: Deployment problem : project doesn't appear in the web c
srenaudo Oct 18, 2006 10:49 AM (in response to srenaudo)Reading the http://wiki.jboss.org/wiki/Wiki.jsp?page=ExplodedDeployment page, it seems that suffixing an exploded directory with ".war" is mandatory.
Ok for that point.
But still, I do no understand why when I'm trying to map a servlet plus a JSP it doesn't work on my JBoss instance, while the same file with only the JSP indicated works...
The "web.xml" which works :<?xml version="1.0"?> <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"> <servlet> <servlet-name>ClientTest</servlet-name> <jsp-file>/client.jsp</jsp-file> </servlet> </web-app>
The one which doesn't work... :<?xml version="1.0"?> <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"> <servlet> <servlet-name>ClientTest</servlet-name> <jsp-file>/client.jsp</jsp-file> </servlet> <servlet> <servlet-name>ControlerServlet</servlet-name> <servlet-class>com.mydomain.myappli.common.ControlerServlet</servlet-class> </servlet> </web-app>
Regards -
2. Re: Deployment problem : project doesn't appear in the web c
peterj Oct 18, 2006 10:52 AM (in response to srenaudo)Your first way did not work because without an extension, JBoss doesn't know what to deploy (a war, an ear, as sar, the list goes on).
For the second and third way, what things do you have defined in your web.xml that you think are causing the problem. I have successfully deployed war files with all kinds of things in web.xml (servlets, filters, ejb refs, etc).
Was there an error printed on the console when you deployed the war? If so, could you post it. -
3. Re: Deployment problem : project doesn't appear in the web c
peterj Oct 18, 2006 10:57 AM (in response to srenaudo)I think I was in the middle of replying to your first post when you made your second post.
I think you need to add a servlet mapping section (I made up a url pattern, you can use any pattern you like):<servlet-mapping> <servlet-name>ControllerServlet</servlet-name> <url-pattern>/controller</url-pattern> </servlet-mapping>
-
4. Re: Deployment problem : project doesn't appear in the web c
srenaudo Oct 18, 2006 11:03 AM (in response to srenaudo)Thanks for your reply PeterJ.
I tried that too but unfortunately adding the <servlet-mapping> makes no change :/
No error is shown in the application console :=============================================================================== . JBoss Bootstrap Environment . JBOSS_HOME: D:\PLATEFORMES\jboss\bin\\.. . JAVA: C:\j2sdk1.4.2_10\bin\java . JAVA_OPTS: -Dprogram.name=run.bat -Xms128m -Xmx512m -Dsun.rmi.dgc.client.gcIn terval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000 . CLASSPATH: C:\j2sdk1.4.2_10\lib\tools.jar;D:\PLATEFORMES\jboss\bin\\run.jar . =============================================================================== . 16:56:19,304 INFO [Embedded] Catalina naming disabled 16:56:19,444 INFO [ClusterRuleSetFactory] Unable to find a cluster rule set in the classpath. Will load the default rule set. 16:56:19,444 INFO [ClusterRuleSetFactory] Unable to find a cluster rule set in the classpath. Will load the default rule set. 16:56:19,896 INFO [Http11BaseProtocol] Initializing Coyote HTTP/1.1 on http-0.0 .0.0-8080 16:56:19,896 INFO [Catalina] Initialization processed in 436 ms 16:56:19,912 INFO [StandardEngine] Starting Servlet Engine: Apache Tomcat/5.5.1 7 16:56:19,958 INFO [StandardHost] XML validation disabled 16:56:19,989 INFO [Catalina] Server startup in 93 ms 16:56:20,504 INFO [WebappLoader] Dual registration of jndi stream handler: factory already defined 16:56:28,624 INFO [Http11BaseProtocol] Starting Coyote HTTP/1.1 on http-0.0.0.0-8080 16:56:28,764 INFO [ChannelSocket] JK: ajp13 listening on /0.0.0.0:8009 16:56:28,780 INFO [JkMain] Jk running ID=0 time=0/94 config=null
Maybe I have to configure Jboss to show me more things at start-up ? But how can I do that ?
Have the classes files to be deployed elsewhere than the /WEB-INF/classes/ directory of my "application.war" directory ?
Regards. -
5. Re: Deployment problem : project doesn't appear in the web c
srenaudo Oct 18, 2006 11:35 AM (in response to srenaudo)The application partly works.
Partly, because I can't define any reference or mapping to a servlet as shwon before.
And I suppose I'll have problems too for configuring CICS access... -
6. Re: Deployment problem : project doesn't appear in the web c
peterj Oct 18, 2006 11:46 AM (in response to srenaudo)I think I know what the issue is. Your controller class has no package. A seem to recall that there is an issue with accessing packageless classes within the web-inf/clases directory (tried looking for the post, but could not find it). I suggest adding a package to your controller class, modify the web.xml accordingly, and try again.
-
7. Re: Deployment problem : project doesn't appear in the web c
srenaudo Oct 23, 2006 4:58 AM (in response to srenaudo)Sorry for my late answer, two days of work spent in training for another subject.
Well, the controler class is defined with an associated package.
But maybe we're not talking about the same "controler class" ?
Moreover, we are using Axis web services. If we can't define servlet mapping in the web.xml, it will be difficult to make them working. -
8. Re: Deployment problem : project doesn't appear in the web c
peterj Oct 23, 2006 12:53 PM (in response to srenaudo)My mistake. I see controller class (servlet) is in a package, not sure why I missed that earlier.
I am curious about the console output you posted earlier. Is this all of the output? If it is, I am surpirsed because I usually get 3 or 4 times as much output as that. So let's go back to a few basic questions:
1) What version of JBoss AS are you working with?
2) How did you install JBoss? By running the installer jar file or by downloading and unzipping the zip file? If the former, what installation options did you choose? -
9. Re: Deployment problem : project doesn't appear in the web c
srenaudo Oct 24, 2006 4:03 AM (in response to srenaudo)It's all of the output... I may have to configure something but had no time to check that since last thursday.
1/ JBoss Application Server 4.04
2/ Downloading the zip file. I use the "run.bat" file to start my JBoss instance.