6 Replies Latest reply on Jan 17, 2011 8:24 AM by callmepuck

    JSFUnit is not compatible with JBoss 5.0.0.GA?

    alartin

      Hi all,
      I run the seam registration jsfunit test on JBoss AS 5.0.0 (JDK 1.5) and failed to deploy the application. Errors are following:
      -------------------------------------------------------------
      Caused by: org.jboss.xb.binding.JBossXBException: Failed to create a new SAX parser
      at org.jboss.xb.binding.parser.sax.SaxJBossXBParser.(SaxJBossXBParser.java:97)
      at org.jboss.xb.binding.UnmarshallerImpl.(UnmarshallerImpl.java:56)
      at org.jboss.xb.binding.UnmarshallerFactory$UnmarshallerFactoryImpl.newUnmarshaller(UnmarshallerFactory.java:96)
      ... 63 more
      Caused by: java.lang.ClassCastException: org.apache.xerces.parsers.XIncludeAwareParserConfiguration
      at org.apache.xerces.parsers.SAXParser.(Unknown Source)
      at org.apache.xerces.parsers.SAXParser.(Unknown Source)
      at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.(Unknown Source)
      at org.apache.xerces.jaxp.SAXParserImpl.(Unknown Source)
      at org.apache.xerces.jaxp.SAXParserFactoryImpl.newSAXParser(Unknown Source)
      at org.jboss.xb.binding.parser.sax.SaxJBossXBParser.(SaxJBossXBParser.java:92)
      ----------------------------------------------
      I wonder if JSFUnit can run on JBoss 5.0.0.GA or later?
      Thanks.

        • 1. Re: JSFUnit is not compatible with JBoss 5.0.0.GA?
          ssilvert

          JSFUnit runs fine on JBoss 5.x. I answered the question about the registration example in your other thread. But do be aware that in JBoss AS 5.x, you should not bundle xerces and xalan in your WAR. That's probably the cause of that particular error.

          Stan

          • 2. JSFUnit is not compatible with JBoss 5.0.0.GA?
            callmepuck

            Hello,

             

            I Installed MAC OS 10.6.6

            Installed JRE 6.0_22

            Installed jboss EAP 5.1

            svn export http://anonsvn.jboss.org/repos/jsfunit/tags/1.3.0.Final/ ~/Work/jboss/JSFUnit

            mvn in ~/Work/jboss/JSFUnit

             

            cp jboss-seam-registration.ear .../EnterprisePlatform-5.1.0/.../deploy

             

             

            I'm getting the following in JBoss EAP log file at deploy time:

             

            18:26:01,660 INFO  [TomcatDeployment] deploy, ctxPath=/seam-registration

            18:26:01,769 ERROR [[/seam-registration]] Exception sending context initialized event to listener instance of class org.jboss.web.jsf.integration.config.JBossJSFConfigureListener

            java.lang.ClassCastException: org.apache.xerces.jaxp.SAXParserFactoryImpl cannot be cast to javax.xml.parsers.SAXParserFactory

                at javax.xml.parsers.SAXParserFactory.newInstance(SAXParserFactory.java:128)

             

             

            Do you know anyone who has a working POM for the current version of jsfunit on the current JBoss EAP server?

             

            Thank you,

             

            Puck

            • 3. JSFUnit is not compatible with JBoss 5.0.0.GA?
              ssilvert

              You need to build with the correct profiles for JBoss 5.x.  See http://labs.jboss.com/jsfunit/building-jsfunit

               

              I'm pretty sure the seam registration demo will work.  I'm not sure about the other one though.

               

              Stan

              • 4. JSFUnit is not compatible with JBoss 5.0.0.GA?
                callmepuck

                Hello Stan,

                 

                 

                Thank you for your time and this quick reply.

                 

                Thank you for mentioning the profile option on the "mvn -Pjee5,jboss5x"

                 

                 

                Installed MAC OS 10.6.6

                Installed JRE 6.0_22

                Installed jboss EAP 5.1

                svn export http://anonsvn.jboss.org/repos/jsfunit/tags/1.3.0.Final/ ~/Work/jboss/JSFUnit

                mvn -Pjee5,jboss5x in ~/Work/jboss/JSFUnit

                 

                cp jboss-seam-registration.ear .../EnterprisePlatform-5.1.0/.../deploy

                 

                 

                I'm getting the following in JBoss EAP log file at deploy time:

                 

                10:23:32,714 WARN  [Initialization] namespace declared in components.xml does not resolve to a package annotated @Namespace: http://jboss.com/products/seam/core

                10:23:32,804 ERROR [[/seam-registration]] Exception sending context initialized event to listener instance of class org.jboss.seam.servlet.SeamListener

                java.lang.NullPointerException

                    at org.jboss.seam.contexts.ServletLifecycle.endInitialization(ServletLifecycle.java:97)

                    at org.jboss.seam.init.Initialization.init(Initialization.java:583)

                    at org.jboss.seam.servlet.SeamListener.contextInitialized(SeamListener.java:34)

                    at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3910)

                 

                 

                I suppose I've been making process compare to yesterday...

                 

                 

                Thank you,

                 

                Puck

                • 5. JSFUnit is not compatible with JBoss 5.0.0.GA?
                  ssilvert

                  I realized that you'll also need to change the Seam version to 2.2.0.GA because that is the Seam version that works with AS 5.1.  The setting for Seam version is in the properties of the main jsfunit pom.xml.

                   

                  I tried it and it still wasn't quite working.  I'm not sure what was wrong but I don't have time to figure it out right now.

                   

                  Stan

                  • 6. JSFUnit is not compatible with JBoss 5.0.0.GA?
                    callmepuck

                    Hello Stan,

                     

                     

                    Thank you for your time and this quick reply.Thank you for mentioning the version of seam I need to use

                     

                     

                    Installed MAC OS 10.6.6

                    Installed JRE 6.0_22

                    Installed jboss EAP 5.1

                    svn export http://anonsvn.jboss.org/repos/jsfunit/tags/1.3.0.Final/ ~/Work/jboss/JSFUnit

                     

                    updated .../JSFUnit/pom.xml with

                        <seam-version>2.2.0.GA</seam-version>

                     

                    updated .../jboss-jsfunit/examples-seam-registration/ear/pom.xml with

                          <version>${seam-version}</version>

                     

                    mvn -Pjee5,jboss5x in ~/Work/jboss/JSFUnit

                     

                    cp jboss-seam-registration.ear .../EnterprisePlatform-5.1.0/.../deploy

                     

                    open http://localhost:8080/seam-registration/register.seam

                     

                    I'm getting the following in JBoss EAP log file:

                     

                    14:21:17,229 ERROR [compiler] Missing Built-in Tag Libraries! Make sure they are included within the META-INF directory of Facelets' Jar

                    14:21:17,319 ERROR [viewhandler] Error Rendering View[/register.xhtml]

                    javax.el.ELException: /register.xhtml: Property 'register' not found on type org.javassist.tmp.java.lang.Object_$$_javassist_seam_2

                        at com.sun.facelets.compiler.AttributeInstruction.write(AttributeInstruction.java:53)

                        at com.sun.facelets.compiler.UIInstructions.encodeBegin(UIInstructions.java:39)

                        at com.sun.facelets.compiler.UILeaf.encodeAll(UILeaf.java:149)

                       

                        

                     

                    I suppose I've been making even further process ...

                     

                     

                    Thank you,

                     

                    Puck