2 Replies Latest reply on Sep 9, 2008 5:35 PM by Ivan Pazmino

    Deployment Exception

    Ivan Pazmino Newbie

      Hi,

      I'm trying to deploy an app to try out RichFaces, but I get the following exception:

      ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/richfaces-test]] Exception sending context initialized event to listener instance of class org.jboss.web.jsf.integration.config.JBossJSFConfigureListener
      com.sun.faces.config.ConfigurationException: CONFIGURATION FAILED! org.ajax4jsf.application.DebugLifecycleFactory
      

      ERROR [StandardContext] Error listenerStart
      ERROR [StandardContext] Context [/richfaces-test] startup failed du
      e to previous errors
      


      I thought it could be caused by the listener in the web.xml file, so I changed it from

      <listener>
       <listener-class>com.sun.faces.config.ConfigureListener</listener-class>
      </listener>
      


      to

      <listener>
       <listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>
      </listener>
      


      but same problem persist.

      I'm deploying over jboss 4.2.3.GA. I've included in my WEB-INF/lib directory myfaces 1.2.4 (api and impl), richfaces 3.2.1 (api, impl and ui) plus the following commons: beanutils, codec, collections, digester, discovery and logging.

      The deployment war structure is the META-INF and WEB-INF folder at the root, the classes, lib and pages folders, and, web and faces-config xml files, inside the WEB-INF folder.

      Any ideas? If further details are needed please let me know. Thanks in advance.

        • 1. Re: Deployment Exception
          Ivan Pazmino Newbie

          According to the http://wiki.jboss.org/wiki/JBossWithJSFCDDL, about using JBoss 4.2.x built-in JSF 1.2 support, the MyFaces jars should not be included in my war.

          But when they are excluded from the WEB-INF/lib in the war file, I get the following error:

          ERROR [[/richfaces-test]] Error configuring application listener of class org.apache.myfaces.webapp.Startup
          ServletContextListener
          java.lang.ClassNotFoundException: org.apache.myfaces.webapp.StartupServletContextListener


          Any ideas?

          • 2. Re: Deployment Exception
            Ivan Pazmino Newbie

            In the other, if this jars are included the following errors are shown:

            INFO [MyfacesConfig] Starting up Tomahawk on the RI-JSF-Implementation.
            INFO [MyfacesConfig] Starting up Tomahawk on the MyFaces-JSF-Implementation
            ERROR [MyfacesConfig] Both MyFaces and the RI are on your classpath. Please make sure to use only one of the two JSF-implementations.


            which leads to the following error:

            INFO [FacesConfigurator] Serialization provider : class org.apache.myfaces.shared_impl.util.serial.DefaultSerialFactory
            INFO [AbstractFacesInitializer] ServletContext 'D:\java\jboss-4.2.3.GA\server\testingField\.\tmp\deploy\tmp31897richfaces-test-exp.war\' initialized.
            ERROR [[/richfaces-test]] Exception sending context initialized event to listener instance of class com.sun.faces.config.ConfigureListener
            com.sun.faces.config.ConfigurationException: CONFIGURATION FAILED! org.ajax4jsf.application.DebugLifecycleFactory


            To avoid this, according to http://wiki.jboss.org/wiki/JBoss5AndMyFaces, the following context param should be added to the web.xml

            <context-param>
             <param-name>org.jboss.jbossfaces.WAR_BUNDLES_JSF_IMPL</param-name>
             <param-value>true</param-value>
            </context-param>


            but then, the same error is presented

            16:32:59,343 INFO [MyfacesConfig] Starting up Tomahawk on the RI-JSF-Implementation.
            16:32:59,343 INFO [MyfacesConfig] Starting up Tomahawk on the MyFaces-JSF-Implementation
            16:32:59,343 ERROR [MyfacesConfig] Both MyFaces and the RI are on your classpath. Please make sure to use only one of th
            e two JSF-implementations.
            16:32:59,390 INFO [FacesConfigurator] Reading standard config META-INF/standard-faces-config.xml
            16:32:59,546 INFO [FacesConfigurator] Reading config : jar:file:/D:/java/jboss-4.2.3.GA/server/testingField/tmp/deploy/
            tmp36083richfaces-test-exp.war/WEB-INF/lib/richfaces-impl-3.2.1.GA.jar!/META-INF/faces-config.xml
            16:32:59,546 INFO [FacesConfigurator] Reading config : jar:file:/D:/java/jboss-4.2.3.GA/server/testingField/tmp/deploy/
            tmp36083richfaces-test-exp.war/WEB-INF/lib/richfaces-ui-3.2.1.GA.jar!/META-INF/faces-config.xml
            16:32:59,562 INFO [FacesConfigurator] Reading config /WEB-INF/faces-config.xml
            16:32:59,781 INFO [FacesConfigurator] Starting up MyFaces-package : myfaces-api in version : 1.2.4 from path : file:/D:
            /java/jboss-4.2.3.GA/server/testingField/tmp/deploy/tmp36083richfaces-test-exp.war/WEB-INF/lib/myfaces-api-1.2.4.jar
            16:32:59,781 INFO [FacesConfigurator] Starting up MyFaces-package : myfaces-impl in version : 1.2.4 from path : file:/D
            :/java/jboss-4.2.3.GA/server/testingField/tmp/deploy/tmp36083richfaces-test-exp.war/WEB-INF/lib/myfaces-impl-1.2.4.jar
            16:32:59,781 INFO [FacesConfigurator] MyFaces-package : tomahawk-sandbox15 not found.
            16:32:59,781 INFO [FacesConfigurator] MyFaces-package : tomahawk-sandbox not found.
            16:32:59,781 INFO [FacesConfigurator] MyFaces-package : tomahawk not found.
            16:32:59,828 WARN [LocaleUtils] Locale name in faces-config.xml null or empty, setting locale to default locale : en_US
            
            16:33:01,156 INFO [FacesConfigurator] Serialization provider : class org.apache.myfaces.shared_impl.util.serial.Default
            SerialFactory
            16:33:01,171 INFO [AbstractFacesInitializer] ServletContext 'D:\java\jboss-4.2.3.GA\server\testingField\.\tmp\deploy\tm
            p36083richfaces-test-exp.war\' initialized.
            16:33:02,187 ERROR [[/richfaces-test]] Exception sending context initialized event to listener instance of class com.sun
            .faces.config.ConfigureListener
            com.sun.faces.config.ConfigurationException: CONFIGURATION FAILED! org.ajax4jsf.application.DebugLifecycleFactory
             at com.sun.faces.config.ConfigManager.initialize(ConfigManager.java:212)
             at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:195)
             at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3856)