2 Replies Latest reply on Sep 29, 2009 11:22 PM by Val Sw

    Jboss Seam Exception - sending context initialized event to listener instance of class JBossJSFConfigureListener

    Val Sw Expert
      Hi,

      Need help for jboss configuration... please suggest.
      Our existing application is not working and we are getting configuration issue while starting jboss, however we created NEW test project with updated rich-faces jars (ver 3.3.1.GA) and it looks fine

      Environment : jboss-4.2.3, jboss-seam-2.0.2.SP1 using updated rich-faces jars (ver 3.3.1.GA)

      Log:
      ----
      15:34:36,373 INFO  [EJBContainer] STARTED EJB: org.jboss.seam.transaction.EjbSynchronizations ejbName: EjbSynchronizations
      15:34:36,405 INFO  [EJB3Deployer] Deployed: file:/C:/jboss-4.2.3/server/default/deploy/TestATPPiclMetaDataSeam.ear/jboss-seam.jar
      15:34:36,405 INFO  [TomcatDeployer] deploy, ctxPath=/TestATPPiclMetaDataSeam, warUrl=.../deploy/TestATPPiclMetaDataSeam.ear/TestATPPiclMetaDataSeam.war/
      15:34:38,314 ERROR [Digester] End event threw exception
      java.lang.IllegalArgumentException: argument type mismatch
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
           at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
           at java.lang.reflect.Method.invoke(Unknown Source)
           at org.apache.commons.beanutils.MethodUtils.invokeMethod(MethodUtils.java:216)
           at org.apache.commons.digester.SetNextRule.end(SetNextRule.java:217)
           at org.apache.commons.digester.Rule.end(Rule.java:253)
      ................
      15:34:38,314 ERROR [[/TestATPPiclMetaDataSeam]] Exception sending context initialized event to listener instance of class org.jboss.web.jsf.integration.config.JBossJSFConfigureListener
      com.sun.faces.config.ConfigurationException: CONFIGURATION FAILED! Error at line 26 char 69: argument type mismatch
           at com.sun.faces.config.ConfigManager.initialize(ConfigManager.java:212)
           at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:195)
           at org.jboss.web.jsf.integration.config.JBossJSFConfigureListener.contextInitialized(JBossJSFConfigureListener.java:71)
           at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3856)
           at org.apache.catalina.core.StandardContext.start(StandardContext.java:4361)
      ................
      Caused by: java.lang.IllegalArgumentException: argument type mismatch
           at org.apache.commons.digester.Digester.createSAXException(Digester.java:3181)
           at org.apache.commons.digester.Digester.createSAXException(Digester.java:3207)
           at org.apache.commons.digester.Digester.endElement(Digester.java:1225)
           at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
      ................
      at com.sun.faces.config.processor.FactoryConfigProcessor.process(FactoryConfigProcessor.java:131)
           at com.sun.faces.config.ConfigManager.initialize(ConfigManager.java:202)
           ... 138 more
      15:34:38,329 INFO  [ServletContextListener] Welcome to Seam 2.0.2.SP1
      .....
      15:34:55,258 ERROR [URLDeploymentScanner] Incomplete Deployment listing:

      --- Incompletely deployed packages ---
      org.jboss.deployment.DeploymentInfo@945c7a42 { url=file:/C:/jboss-4.2.3/server/default/deploy/TestATPPiclMetaDataSeam.ear/TestATPPiclMetaDataSeam.war/ }
        deployer: MBeanProxyExt[jboss.web:service=WebServer]
        status: Deployment FAILED reason: URL file:/C:/jboss-4.2.3/server/default/deploy/TestATPPiclMetaDataSeam.ear/TestATPPiclMetaDataSeam.war/ deployment failed
        state: FAILED
        watch: file:/C:/jboss-4.2.3/server/default/deploy/TestATPPiclMetaDataSeam.ear/TestATPPiclMetaDataSeam.war/WEB-INF/web.xml
        altDD: null
        lastDeployed: 1254166470475
        lastModified: 1254164493668
        mbeans:

      org.jboss.deployment.DeploymentInfo@4a09267 { url=file:/C:/jboss-4.2.3/server/default/deploy/TestATPPiclMetaDataSeam.ear/ }
        deployer: org.jboss.deployment.EARDeployer@3526cf
        status: Deployment FAILED reason: URL file:/C:/jboss-4.2.3/server/default/deploy/TestATPPiclMetaDataSeam.ear/TestATPPiclMetaDataSeam.war/ deployment failed
        state: FAILED
        watch: file:/C:/jboss-4.2.3/server/default/deploy/TestATPPiclMetaDataSeam.ear/META-INF/application.xml
        altDD: null
        lastDeployed: 1254166470475
        lastModified: 1254164511395
        mbeans:
          persistence.units:ear=TestATPPiclMetaDataSeam.ear,jar=TestATPPiclMetaDataSeam.jar,unitName=TestATPPiclMetaDataSeam state: Started
          jboss.j2ee:ear=TestATPPiclMetaDataSeam.ear,jar=TestATPPiclMetaDataSeam.jar,name=Utils,service=EJB3 state: Started
          jboss.j2ee:ear=TestATPPiclMetaDataSeam.ear,jar=jboss-seam.jar,name=TimerServiceDispatcher,service=EJB3 state: Started
          jboss.j2ee:ear=TestATPPiclMetaDataSeam.ear,jar=jboss-seam.jar,name=EjbSynchronizations,service=EJB3 state: Started

      --- MBeans waiting for other MBeans ---
      ObjectName: jboss.web.deployment:war=TestATPPiclMetaDataSeam.war,id=-1805878718
        State: FAILED
        Reason: org.jboss.deployment.DeploymentException: URL file:/C:/jboss-4.2.3/server/default/deploy/TestATPPiclMetaDataSeam.ear/TestATPPiclMetaDataSeam.war/ deployment failed

      --- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM ---
      ObjectName: jboss.web.deployment:war=TestATPPiclMetaDataSeam.war,id=-1805878718
        State: FAILED
        Reason: org.jboss.deployment.DeploymentException: URL file:/C:/jboss-4.2.3/server/default/deploy/TestATPPiclMetaDataSeam.ear/TestATPPiclMetaDataSeam.war/ deployment failed

      Web.xml
      -------
      <?xml version="1.0" ?>
      <web-app xmlns="http://java.sun.com/xml/ns/javaee"
               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
               version="2.5">

          <!-- Ajax4jsf -->   
          <context-param>
              <param-name>org.richfaces.SKIN</param-name>
              <param-value>blueSky</param-value>
          </context-param>   
          <context-param>
              <param-name>javax.faces.CONFIG_FILES</param-name>
              <param-value>/WEB-INF/faces-config.xml</param-value>
          </context-param>
          <context-param>
              <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
              <param-value>server</param-value>
          </context-param>
          <context-param>
              <param-name>org.ajax4jsf.COMPRESS_SCRIPT</param-name>
              <param-value>false</param-value>
          </context-param>

         <!-- Seam -->   
         <listener>
            <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>
         </listener>
         
          <filter>
              <filter-name>Seam Filter</filter-name>
              <filter-class>org.jboss.seam.servlet.SeamFilter</filter-class>
          </filter>

          <filter-mapping>
              <filter-name>Seam Filter</filter-name>
              <url-pattern>/*</url-pattern>
          </filter-mapping>
             
         <servlet>
            <servlet-name>Seam Resource Servlet</servlet-name>
            <servlet-class>org.jboss.seam.servlet.SeamResourceServlet</servlet-class>
         </servlet>
         
         <servlet-mapping>
            <servlet-name>Seam Resource Servlet</servlet-name>
            <url-pattern>/seam/resource/*</url-pattern>
         </servlet-mapping>
        
          <filter>
              <display-name>Ajax4jsf Filter</display-name>
              <filter-name>ajax4jsf</filter-name>
              <filter-class>org.ajax4jsf.Filter</filter-class>
          </filter>
         
          <filter-mapping>
              <filter-name>ajax4jsf</filter-name>
              <servlet-name>Faces Servlet</servlet-name>
              <dispatcher>REQUEST</dispatcher>
              <dispatcher>FORWARD</dispatcher>
              <dispatcher>INCLUDE</dispatcher>
          </filter-mapping>
        
         <!-- Facelets development mode (disable in production) -->  
         <context-param>
            <param-name>facelets.DEVELOPMENT</param-name>
            <param-value>true</param-value>
         </context-param>
         
         <!-- JSF -->  
         <context-param>
            <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
            <param-value>.xhtml</param-value>
         </context-param>
        
         <servlet>
            <servlet-name>Faces Servlet</servlet-name>
            <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
            <load-on-startup>1</load-on-startup>
         </servlet>
         
         <servlet-mapping>
            <servlet-name>Faces Servlet</servlet-name>
            <url-pattern>*.seam</url-pattern>
         </servlet-mapping>
                       
         <security-constraint>
             <display-name>Restrict raw XHTML Documents</display-name>
             <web-resource-collection>
                 <web-resource-name>XHTML</web-resource-name>
                 <url-pattern>*.xhtml</url-pattern>
             </web-resource-collection>
             <auth-constraint/>
         </security-constraint>  
      </web-app>
        • 1. Re: Jboss Seam Exception - sending context initialized event to listener instance of class JBossJSFConfigureListener
          Val Sw Expert
          Hi,

          I am trying to deploy existing application developed using jboss-4.2.3, jboss-seam-2.0.2.SP1.
          We only changed richfaces version to 3.3.1.

          Please suggest ...

          -When application is deployed, why it is not able to read jars from "...\jboss-4.2.3\server\default\deploy\TestATPPiclMetaDataSeam.ear\TestATPPiclMetaDataSeam.war\WEB-INF\lib"...

          -List of jars under WEB-INF\lib
          commons-beanutils.jar, commons-digester.jar, jboss-seam-debug.jar, jboss-seam-ioc.jar
          jboss-seam-mail.jar, jboss-seam-pdf.jar, jboss-seam-remoting.jar, jboss-seam-ui.jar
          jsf-facelets.jar, richfaces-ui-3.3.1.GA.jar

          -jsf-facelets.jar exists under it but we get exception as
          java.lang.NoClassDefFoundError: com/sun/facelets/tag/jsf/ComponentHandler

          -If I place jsf-facelets.jar under "...\jboss-4.2.3\server\default\lib", we get exception as ...
          12:29:22,163 INFO  [Contexts] starting up: org.jboss.seam.web.session
          12:29:23,319 ERROR [STDERR] Sep 29, 2009 12:29:23 PM com.sun.facelets.compiler.TagLibraryConfig loadImplicit
          SEVERE: Error Loading Library: jar:file:/C:/jboss-4.2.3/server/default/deploy/TestATPPiclMetaDataSeam.ear/lib/richfaces-ui-3.3.1.GA.jar!/META-INF/a4j.taglib.xml
          java.io.IOException: Error parsing [jar:file:/C:/jboss-4.2.3/server/default/deploy/TestATPPiclMetaDataSeam.ear/lib/richfaces-ui-3.3.1.GA.jar!/META-INF/a4j.taglib.xml]:
                  at com.sun.facelets.compiler.TagLibraryConfig.create(TagLibraryConfig.java:410)
          ...
          Caused by: org.xml.sax.SAXException: Error Handling [jar:file:/C:/jboss-4.2.3/server/default/deploy/TestATPPiclMetaDataSeam.ear/lib/richfaces-ui-3.3.1.GA.jar!/META-INF/a4j.taglib.xml@27,93] <handler-class>
                  at com.sun.facelets.compiler.TagLibraryConfig$LibraryHandler.endElement(TagLibraryConfig.java:271)
          ...
          Caused by: java.lang.Exception: org.ajax4jsf.webapp.taglib.AjaxComponentHandler must be an instance of com.sun.facelets.tag.TagHandler
                  at com.sun.facelets.compiler.TagLibraryConfig$LibraryHandler.createClass(TagLibraryConfig.java:293)

          • 2. Re: Jboss Seam Exception - sending context initialized event to listener instance of class JBossJSFConfigureListener
            Val Sw Expert

            It is fine now...


            Recreated the project from scratch, but still required to place richfaces jars under ear