-
1. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
ssilvert Jul 17, 2012 7:58 AM (in response to mukulgoel)For 7.2, WAR_BUNDLES_JSF_IMPL should work. That is, you set that context param in web.xml and bundle JSF with your WAR. Before, this would only fully work if you were bundling MyFaces 1.2 or earlier.
We are looking at the possibility of allowing you to install multiple JSF versions into AS so that you don't have to bundle them with your WAR. I don't know if that will be done before 7.2 final.
Stan
-
2. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
mukulgoel Jul 17, 2012 9:28 AM (in response to ssilvert)switched to jsf2 as u suggested... packed the jsf n jsf-impl jars inside lib..turned the parameter true.. and getting this error while starting application
8:35:38,513 INFO [org.apache.catalina.core.StandardContext] (MSC service thread 1-4) The listener "com.sun.faces.config.ConfigureListener" is already configured for this context. The duplicate definition has been ignored.
18:35:39,456 ERROR [org.apache.catalina.core.StandardContext] (MSC service thread 1-4) Error listenerStart
18:35:39,457 ERROR [org.apache.catalina.core.StandardContext] (MSC service thread 1-4) Context [/csa] startup failed due to previous errors
18:35:39,458 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-4) MSC00001: Failed to start service jboss.web.deployment.default-host./csa: org.jboss.msc.service.StartException in service jboss.web.deployment.default-host./csa: JBAS018040: Failed to start context
at org.jboss.as.web.deployment.WebDeploymentService.start(WebDeploymentService.java:95)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) [rt.jar:1.6.0_32]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [rt.jar:1.6.0_32]
at java.lang.Thread.run(Unknown Source) [rt.jar:1.6.0_32]
18:35:39,672 INFO [org.jboss.as.server] (DeploymentScanner-threads - 1) JBAS015870: Deploy of deployment "csaEARDev.ear" was rolled back with failure message {"JBAS014671: Failed services" => {"jboss.web.deployment.default-host./csa" => "org.jboss.msc.service.StartException in service jboss.web.deployment.default-host./csa: JBAS018040: Failed to start context"},"JBAS014771: Services with missing/unavailable dependencies" => ["jboss.deployment.subunit.\"csaEARDev.ear\".\"csaDev.war\".jboss.security.jacc Missing[JBAS014861: <one or more transitive dependencies>]"]}
18:35:39,672 INFO [org.jboss.as.controller] (DeploymentScanner-threads - 1) JBAS014774: Service status report
JBAS014777: Services which failed to start: service jboss.web.deployment.default-host./csa: org.jboss.msc.service.StartException in service jboss.web.deployment.default-host./csa: JBAS018040: Failed to start context
18:35:39,679 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 2) {"JBAS014653: Composite operation failed and was rolled back. Steps that failed:" => {"Operation step-2" => {"JBAS014671: Failed services" => {"jboss.web.deployment.default-host./csa" => "org.jboss.msc.service.StartException in service jboss.web.deployment.default-host./csa: JBAS018040: Failed to start context"},"JBAS014771: Services with missing/unavailable dependencies" => ["jboss.deployment.subunit.\"csaEARDev.ear\".\"csaDev.war\".jboss.security.jacc Missing[JBAS014861: <one or more transitive dependencies>]"]}}}
18:35:40,471 INFO [org.jboss.as.server.deployment] (MSC service thread 1-1) JBAS015877: Stopped deployment csaDev.war in 799ms
18:35:40,650 INFO [org.jboss.as.server.deployment] (MSC service thread 1-2) JBAS015877: Stopped deployment csaEARDev.ear in 977ms
-
3. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
ssilvert Jul 17, 2012 12:06 PM (in response to mukulgoel)Perhaps you don't have this in your web.xml?
<context-param> <param-name>org.jboss.jbossfaces.WAR_BUNDLES_JSF_IMPL</param-name> <param-value>true</param-value> </context-param>
Another thing you can try is to remove the JSF subsystem. You will find that in standalone.xml or domain.xml starting a couple of weeks ago with AS7.2.
Also, how are you getting AS7.2 Alpha? Are you building it from master? How old is it? If it's not pretty a new version then my instructions won't work.
Stan
-
4. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
mukulgoel Jul 18, 2012 4:11 AM (in response to ssilvert)Stan,
I have that entry in my web.xml but still getting that error.
is AS7.2 Alpha aint a stable version to migrate to. i was browsing through and someone suggested me to use this version and gave the link for. its been 1.5-2 months when i downloaded it.
in the readme.txt it says "Welcome to JBoss Application Server 7.1.1" , so what exactly is the version ? :/ # confused
and yes as u said there are no entries for jsf subsytem in either standalone.xml / domain.xml
-
5. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
ssilvert Jul 18, 2012 8:01 AM (in response to mukulgoel)In that case, you need to try a newer version of 7.2 Alpha.
You can get the latest nightly build here:
http://hudson.jboss.org/hudson/view/JBoss%20AS/job/JBoss-AS-7.0.x/lastBuild/artifact/build/target/
Stan
-
6. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
mukulgoel Jul 18, 2012 9:49 AM (in response to ssilvert)Thanks stan, will surely do so..
I know this is not the appropriate thread.. but can u just tell me is the issue
resolved in the current version i have and/or the version u are providing me link to.
-
7. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
ctomc Jul 18, 2012 9:53 AM (in response to mukulgoel)Hi,
AS7-2977 was fixed in december 2011, that means it was fixed in 7.1.0.CR1 and all later builds.
-
8. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
mukulgoel Jul 19, 2012 3:40 AM (in response to ctomc)Stan,
Thank you, that worked. downloaded the new version of JBoss, set up the context param to true and removed the subsystem from standalone.xml and domail.xml and it worked.
@Tomaz : yes i see that is fixed in JIRA and the sun/io package is there in module.xml .. but i am getting the same error while trying to execute a SELECT querry on DB2 (the querry is correct)
-
9. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
mukulgoel Jul 19, 2012 8:20 AM (in response to mukulgoel)Stan/Tomaz
Could u refer me the link to latest stable release of JBoss? I think I should try my app on the stable release rather than a ALPHA
I am asking this in response to
https://community.jboss.org/thread/202344
I know as u communicated this issue has been fixed in Dec`11..
but i am , on the latest build of JBoss that i downloaded from
http://hudson.jboss.org/hudson/view/JBoss%20AS/job/JBoss-AS-7.0.x/lastBuild/artifact/build/target/
still getting this issue.
-
10. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
mukulgoel Jul 24, 2012 9:29 AM (in response to mukulgoel)Hi Stan,
I had it working, but i was debuggint into my application and found out that, my code is accessing C:\JBoss7.2\jboss-as-7.2.0.Alpha1-SNAPSHOT\modules\javax\faces\api\main\jboss-jsf-api_2.1_spec-2.0.3.Final.jar insted of jsf.jar i bundled insdie the WAR.
I guess the earler workaround u mentioned, was only for JSF-IMPL ?
how do i get JBoss to use the jsf.jar i provided inside war.
-
11. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
ssilvert Jul 24, 2012 11:15 AM (in response to mukulgoel)Under AS7.2 that should not happen if you are using WAR_BUNDLES_JSF_IMPL and/or you have removed the JSF subsystem.
Are you sure that your app is seeing jboss-jsf-api_2.1_spec-2.0.3.Final.jar at run time? I don't trust the debug setup. Try just running AS7 from outside Eclipse and run java with the -verbose:class setting. Then when your WAR is deployed you will see for sure where the JSF API is coming from. If it is not coming from your WEB-INF/lib then we probably have a bug in AS7.
Stan
-
12. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
mukulgoel Jul 25, 2012 3:53 AM (in response to ssilvert)Hey Stan,
i did set
set "JAVA_OPTS=%JAVA_OPTS% -verbose:class" in standalone.bat
i am attaching the output file that it gave me. All the classes that are loaded
I see entries to both the jboss-jsf-api_2.1_spec-2.0.3.Final.jar that JBoss provides and jsf-api.jar that i provided inside war. i am not sure if thats the desired behaviour. could u please take a look at the attached file and see if its the desired behavior or its a bug.
-
output.txt.zip 111.3 KB
-
-
13. Re: Use JSF2.0 with JBOSS AS7.2 ALPHA
ssilvert Jul 25, 2012 8:11 AM (in response to mukulgoel)mukul goel wrote:
Hey Stan,
i did set
set "JAVA_OPTS=%JAVA_OPTS% -verbose:class" in standalone.bat
i am attaching the output file that it gave me. All the classes that are loaded
I see entries to both the jboss-jsf-api_2.1_spec-2.0.3.Final.jar that JBoss provides and jsf-api.jar that i provided inside war. i am not sure if thats the desired behaviour. could u please take a look at the attached file and see if its the desired behavior or its a bug.
I opened your file and searched on "jboss-jsf" and it was not found. Looks to me like it worked.