1 Reply Latest reply on Dec 17, 2016 11:47 PM by pjhavariotis

    Primefaces as modules

    mistrz_7

      Hello,

       

      I develop web application using primefaces, app is deployed to jbosseap 7. When primefaces-5.3 lib is in WEB/lib directory of war app, it's corectly deployed to jboss and works fine. After deploy

      application in log server I see:

      20:27:11,094 INFO  [javax.enterprise.resource.webcontainer.jsf.config] (ServerService Thread Pool -- 6) Initializing Mojarra 2.2.12-jbossorg-2  for context '/my_app'

      20:27:12,063 INFO  [org.primefaces.webapp.PostConstructApplicationEventListener] (ServerService Thread Pool -- 6) Running on PrimeFaces 5.3

       

      Becouse primefaces lib is about 3,3 MB I extract it jboss module. In my app I have create jboss-deployment-structure.xml file:

      <?xml version="1.0" encoding="UTF-8"?> 

      <jboss-deployment-structure> 

          <deployment> 

              <dependencies>   

                  <module name="com.google.guava" />

                  <module name="org.primefaces"/>

                  <module name="javax.faces.api" />

              </dependencies> 

          </deployment> 

      </jboss-deployment-structure> 

      And in pom file I add to primefaces dependency provided scope.

      Now app is correctly deployed too, but in my log I see only:

      20:32:18,952 INFO  [javax.enterprise.resource.webcontainer.jsf.config] (ServerService Thread Pool -- 83) Initializing Mojarra 2.2.12-jbossorg-2  for context '/my_app'

      Application is generally avalible, but primefaces elements are not visible.

      As I understand jboss deployed application but use mojarra not primefaces as jsf provider.

      My question is, how to tell jboss that application should use primefaces from module? I tried to add to web.xml:

      <context-param>

      <param-name>org.jboss.jbossfaces.JSF_CONFIG_NAME</param-name>

      <param-value>primefaces-5.3</param-value>

      </context-param>

      But this don't resolve problem.

       

      Best regards

      sw