6 Replies Latest reply on Nov 26, 2008 9:56 AM by chawax

    Could not create Component: org.jboss.seam.core.validators

    mangelo123

      I am using JBoss Tools just to create a basic CRUD against a mySQL database with just a few tables. I am trying to deploy against Tomcat 6.x as a WAR only. I have checked all of my JAR dependencies and they are all correct. I see this exception when Tomcat starts. It says it cannon create the seam validators and then below it says it can't find the Hibernate Validator Class Validator.



      java.lang.RuntimeException: Could not create Component: org.jboss.seam.core.validators
              at org.jboss.seam.init.Initialization.addComponent(Initialization.java:989)
              at org.jboss.seam.init.Initialization.installComponents(Initialization.java:911)
              at org.jboss.seam.init.Initialization.init(Initialization.java:589)
              at org.jboss.seam.servlet.SeamListener.contextInitialized(SeamListener.java:34)
              at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3843)
              at org.apache.catalina.core.StandardContext.start(StandardContext.java:4342)
              at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
              at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
              at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
              at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
              at org.apache.catalina.core.StandardService.start(StandardService.java:516)
              at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
              at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
              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.catalina.startup.Bootstrap.start(Bootstrap.java:288)
              at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
      Caused by: java.lang.NoClassDefFoundError: org/hibernate/validator/ClassValidator
              at java.lang.Class.getDeclaredMethods0(Native Method)
              at java.lang.Class.privateGetDeclaredMethods(Unknown Source)
              at java.lang.Class.privateGetPublicMethods(Unknown Source)
              at java.lang.Class.getMethods(Unknown Source)
              at org.jboss.seam.Component.hasAnnotation(Component.java:1070)
              at org.jboss.seam.Component.<init>(Component.java:229)
              at org.jboss.seam.Component.<init>(Component.java:217)
              at org.jboss.seam.init.Initialization.addComponent(Initialization.java:974)
              ... 18 more
      Caused by: java.lang.ClassNotFoundException: org.hibernate.validator.ClassValidator
              at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1387)
              at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1233)
              at java.lang.ClassLoader.loadClassInternal(Unknown Source)
              ... 26 more
      
      


        • 1. Re: Could not create Component: org.jboss.seam.core.validators

          Well, list all jars you have...

          • 2. Re: Could not create Component: org.jboss.seam.core.validators
            mangelo123

            These jars are a result of a quick test of JBoss Tools under the latest Eclipse. I can build this application with no errors with JBoss Developer Studio deployed against JBoss 4.2.x AS.


            Here are the JAR files for the Tomcat version using Eclipse:


            antlr-2.7.6.jar
            antlr-runtime.jar
            asm-attrs.jar
            asm.jar
            c3p0-0.9.1.jar
            cglib.jar
            commons-beanutils.jar
            commons-collections-3.1.jar
            commons-digester.jar
            commons-logging.jar
            concurrent.jar
            core.jar
            dom4j-1.6.1.jar
            drools-compiler.jar
            drools-core.jar
            ehcache-1.2.3.jar
            ejb3-persistence.jar
            hibernate-annotations.jar
            hibernate-commons-annotations.jar
            hibernate-entitymanager.jar
            hibernate3.jar
            javassist.jar
            jboss-el.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
            jboss-seam.jar
            jbpm-jpdl.jar
            jsf-facelets.jar
            jta.jar
            mvel14.jar
            richfaces-api.jar
            richfaces-impl.jar
            richfaces-ui.jar


            • 3. Re: Could not create Component: org.jboss.seam.core.validators
              mangelo123

              Sorry...


              antlr-2.7.6.jar
              antlr-runtime.jar
              asm-attrs.jar
              asm.jar
              c3p0-0.9.1.jar
              cglib.jar
              commons-beanutils.jar
              commons-collections-3.1.jar
              commons-digester.jar
              commons-logging.jar
              concurrent.jar
              core.jar
              dom4j-1.6.1.jar
              drools-compiler.jar
              drools-core.jar
              ehcache-1.2.3.jar
              ejb3-persistence.jar
              hibernate-annotations.jar
              hibernate-commons-annotations.jar
              hibernate-entitymanager.jar
              hibernate3.jar
              javassist.jar
              jboss-el.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
              jboss-seam.jar
              jbpm-jpdl.jar
              jsf-facelets.jar
              jta.jar
              mvel14.jar
              richfaces-api.jar
              richfaces-impl.jar
              richfaces-ui.jar




              • 4. Re: Could not create Component: org.jboss.seam.core.validators
                mangelo123

                I just tried a test with JBoss Developer Studio 1.1 with an Apache Tomcat 6 deployment. This time its complaining about javassist classes not found when it clearly is included in the build path.


                What causes this?

                • 5. Re: Could not create Component: org.jboss.seam.core.validators
                  mangelo123

                  I've just noticed that the jar files that I add as 'User Libraries' are not copied to the deployed project under the WEB-INF/lib directory. I know I've handled libraries like this in the past. Is this a bug?

                  • 6. Re: Could not create Component: org.jboss.seam.core.validators
                    chawax

                    It looks like you miss hibernate-validator.jar.