14 Replies Latest reply on Jan 24, 2008 8:11 AM by Pete Muir

    FailedConfiguration while running test

    Hussein Baghdadi Novice

      Hi.
      I got this exception upon trying to run my POJO Seam application:
      EDU/oswego/cs/dl/util/concurrent/ConcurrentReaderHashMap
      Failed configuration @BeforClass init
      Any ideas?
      Thanks for help.

        • 1. Re: FailedConfiguration while running test
          Nicklas Karlsson Master

          PTFSTP (post the full stacktrace, please)

          • 2. Re: FailedConfiguration while running test
            Hussein Baghdadi Novice

            As a general rule:
            Should I include bootstrap folder of Seam's package if I want to test my POJO application?

            • 3. Re: FailedConfiguration while running test
              Pete Muir Master

              For integration tests, yes.

              • 4. Re: FailedConfiguration while running test
                Hussein Baghdadi Novice

                 

                 [testng] FAILED CONFIGURATION: @BeforeClass init
                 [testng] java.lang.NoClassDefFoundError: EDU/oswego/cs/dl/util/concurrent/ConcurrentReaderHashMap
                 [testng] at org.jboss.util.collection.CollectionsFactory.createConcurrentReaderMap(CollectionsFactory.java:73)
                 [testng] at org.jboss.kernel.plugins.event.AbstractEventEmitter.<init>(AbstractEventEmitter.java:60)
                 [testng] at org.jboss.kernel.plugins.AbstractKernelObject.<init>(AbstractKernelObject.java:47)
                 [testng] at org.jboss.kernel.plugins.bootstrap.AbstractBootstrap.<init>(AbstractBootstrap.java:51)
                 [testng] at org.jboss.kernel.plugins.bootstrap.basic.BasicBootstrap.<init>(BasicBootstrap.java:58)
                 [testng] at org.jboss.embedded.Bootstrap.createKernel(Bootstrap.java:130)
                 [testng] at org.jboss.embedded.Bootstrap.getInstance(Bootstrap.java:76)
                 [testng] at org.jboss.seam.mock.EmbeddedBootstrap.startAndDeployResources(EmbeddedBootstrap.java:10)
                 [testng] at org.jboss.seam.mock.BaseSeamTest.startJbossEmbeddedIfNecessary(BaseSeamTest.java:1006)
                 [testng] at org.jboss.seam.mock.BaseSeamTest.init(BaseSeamTest.java:931)
                 [testng] at org.jboss.seam.mock.SeamTest.init(SeamTest.java:42)
                 [testng] ... Removed 22 stack frames
                 [testng] SKIPPED CONFIGURATION: @BeforeMethod begin
                 [testng] SKIPPED CONFIGURATION: @AfterMethod end
                 [testng] SKIPPED CONFIGURATION: @AfterClass cleanup
                 [testng] SKIPPED: siimulateBijection
                 [testng]
                


                • 5. Re: FailedConfiguration while running test
                  Hussein Baghdadi Novice

                  BTW, my ant build file is the one that is listed in Michael Yuan's book "JBoss Seam"

                  • 6. Re: FailedConfiguration while running test
                    Pete Muir Master

                    So you are using Seam 1.2?

                    • 7. Re: FailedConfiguration while running test
                      Hussein Baghdadi Novice

                      I use Seam 2.0 GA, JDK6, JBoss4.2, Ubuntu 7.10
                      I dropped my Ant build file and used the one that is generated by seam-gen tool, but this time I got this exception:

                       [testng] ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] Error installing to Instantiated: name=DeploymentFilter state=Described
                       [testng] java.lang.IllegalStateException: Class not found: [Ljava.lang.String;
                       [testng] at org.jboss.metadata.spi.signature.Signature.stringsToClasses(Signature.java:174)
                       [testng] at org.jboss.metadata.spi.signature.Signature.stringsToClasses(Signature.java:125)
                       [testng] at org.jboss.metadata.spi.signature.Signature.getParametersTypes(Signature.java:292)
                       [testng] at org.jboss.metadata.plugins.loader.reflection.AnnotatedElementMetaDataLoader.getComponentMetaDataRetrieval(AnnotatedElementMetaDataLoader.java:138)
                       [testng] at org.jboss.metadata.plugins.context.AbstractMetaDataContext.getComponentMetaDataRetrieval(AbstractMetaDataContext.java:280)
                       [testng] at org.jboss.metadata.spi.retrieval.MetaDataRetrievalToMetaDataBridge.getComponentMetaData(MetaDataRetrievalToMetaDataBridge.java:159)
                       [testng] at org.jboss.aop.microcontainer.integration.AOPConstructorJoinpoint.methodHasAnnotations(AOPConstructorJoinpoint.java:202)
                       [testng] at org.jboss.aop.microcontainer.integration.AOPConstructorJoinpoint.hasMethodMetaData(AOPConstructorJoinpoint.java:172)
                       [testng] at org.jboss.aop.microcontainer.integration.AOPConstructorJoinpoint.hasInstanceOrJoinpointMetaData(AOPConstructorJoinpoint.java:152)
                       [testng] at org.jboss.aop.microcontainer.integration.AOPConstructorJoinpoint.dispatch(AOPConstructorJoinpoint.java:99)
                       [testng] at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dispatchJoinPoint(KernelControllerContextAction.java:103)
                       [testng] at org.jboss.kernel.plugins.dependency.InstantiateAction.installActionInternal(InstantiateAction.java:52)
                       [testng] at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.installAction(KernelControllerContextAction.java:197)
                       [testng] at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.install(KernelControllerContextAction.java:136)
                       [testng] at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51)
                       [testng] at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:233)
                       [testng] at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:724)
                       [testng] at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:445)
                       [testng] at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:555)
                       [testng] at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:489)
                       [testng] at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:289)
                       [testng] at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:192)
                       [testng] at org.jboss.kernel.plugins.deployment.AbstractKernelDeployer.deployBean(AbstractKernelDeployer.java:302)
                       [testng] at org.jboss.kernel.plugins.deployment.AbstractKernelDeployer.deployBeans(AbstractKernelDeployer.java:272)
                       [testng] at org.jboss.kernel.plugins.deployment.AbstractKernelDeployer.deploy(AbstractKernelDeployer.java:119)
                       [testng] at org.jboss.kernel.plugins.deployment.xml.BeanXMLDeployer.deploy(BeanXMLDeployer.java:96)
                       [testng] at org.jboss.embedded.Bootstrap.deployBaseBootstrapUrl(Bootstrap.java:150)
                       [testng] at org.jboss.embedded.Bootstrap.bootstrapURL(Bootstrap.java:162)
                       [testng] at org.jboss.embedded.Bootstrap.bootstrap(Bootstrap.java:201)
                       [testng] at org.jboss.embedded.Bootstrap.bootstrap(Bootstrap.java:214)
                       [testng] at org.jboss.seam.mock.EmbeddedBootstrap.startAndDeployResources(EmbeddedBootstrap.java:11)
                       [testng] at org.jboss.seam.mock.BaseSeamTest.startJbossEmbeddedIfNecessary(BaseSeamTest.java:1006)
                       [testng] at org.jboss.seam.mock.BaseSeamTest.init(BaseSeamTest.java:931)
                       [testng] at org.jboss.seam.mock.SeamTest.init(SeamTest.java:42)
                       [testng] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                       [testng] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                       [testng] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                       [testng] at java.lang.reflect.Method.invoke(Method.java:597)
                       [testng] at org.testng.internal.MethodHelper.invokeMethod(MethodHelper.java:604)
                       [testng] at org.testng.internal.Invoker.invokeConfigurationMethod(Invoker.java:394)
                       [testng] at org.testng.internal.Invoker.invokeConfigurations(Invoker.java:142)
                       [testng] at org.testng.internal.Invoker.invokeConfigurations(Invoker.java:79)
                       [testng] at org.testng.internal.TestMethodWorker.invokeBeforeClassMethods(TestMethodWorker.java:165)
                       [testng] at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:103)
                       [testng] at org.testng.TestRunner.runWorkers(TestRunner.java:678)
                       [testng] at org.testng.TestRunner.privateRun(TestRunner.java:624)
                       [testng] at org.testng.TestRunner.run(TestRunner.java:495)
                       [testng] at org.testng.SuiteRunner.runTest(SuiteRunner.java:300)
                       [testng] at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:295)
                       [testng] at org.testng.SuiteRunner.privateRun(SuiteRunner.java:275)
                       [testng] at org.testng.SuiteRunner.run(SuiteRunner.java:190)
                       [testng] at org.testng.TestNG.createAndRunSuiteRunners(TestNG.java:792)
                       [testng] at org.testng.TestNG.runSuitesLocally(TestNG.java:765)
                       [testng] at org.testng.TestNG.run(TestNG.java:699)
                       [testng] at org.testng.TestNG.privateMain(TestNG.java:824)
                       [testng] at org.testng.TestNG.main(TestNG.java:802)
                       [testng] Caused by: java.lang.ClassNotFoundException: [Ljava.lang.String;
                       [testng] at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
                       [testng] at java.security.AccessController.doPrivileged(Native Method)
                       [testng] at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
                       [testng] at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
                       [testng] at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
                       [testng] at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
                       [testng] at org.jboss.metadata.spi.signature.Signature.stringsToClasses(Signature.java:170)
                       [testng] ... 55 more
                       [testng] FAILED CONFIGURATION: @BeforeClass init
                       [testng] org.jboss.deployers.spi.IncompleteDeploymentException: Summary of incomplete deployments (SEE PREVIOUS ERRORS FOR DETAILS):
                       [testng]
                       [testng] *** CONTEXTS MISSING DEPENDENCIES: Name -> Dependency{Required State:Actual State}
                       [testng]
                       [testng] ResourcesToDeploy
                       [testng] -> DeploymentFilter{Configured:**ERROR**}
                       [testng]
                       [testng] ResourcesToDeploy2
                       [testng] -> DeploymentFilter{Configured:**ERROR**}
                       [testng]
                       [testng] ResourcesToDeploy3
                       [testng] -> jboss.kernel:service=Kernel{Configured:**ERROR**}
                       [testng] -> DeploymentFilter{Configured:**ERROR**}
                       [testng]
                       [testng]
                       [testng] *** CONTEXTS IN ERROR: Name -> Error
                       [testng]
                       [testng] DeploymentFilter -> java.lang.ClassNotFoundException: [Ljava.lang.String;
                       [testng]
                       [testng] jboss.kernel:service=Kernel -> **ERROR**
                       [testng]
                       [testng]
                       [testng] at org.jboss.embedded.Bootstrap.checkIncomplete(Bootstrap.java:144)
                       [testng] at org.jboss.embedded.Bootstrap.bootstrapURL(Bootstrap.java:169)
                       [testng] at org.jboss.embedded.Bootstrap.bootstrap(Bootstrap.java:201)
                       [testng] at org.jboss.embedded.Bootstrap.bootstrap(Bootstrap.java:214)
                       [testng] at org.jboss.seam.mock.EmbeddedBootstrap.startAndDeployResources(EmbeddedBootstrap.java:11)
                       [testng] at org.jboss.seam.mock.BaseSeamTest.startJbossEmbeddedIfNecessary(BaseSeamTest.java:1006)
                       [testng] at org.jboss.seam.mock.BaseSeamTest.init(BaseSeamTest.java:931)
                       [testng] at org.jboss.seam.mock.SeamTest.init(SeamTest.java:42)
                       [testng] ... Removed 22 stack frames
                       [testng] SKIPPED CONFIGURATION: @BeforeMethod begin
                       [testng] SKIPPED CONFIGURATION: @AfterMethod end
                       [testng] SKIPPED CONFIGURATION: @AfterClass cleanup
                       [testng] SKIPPED: siimulateBijection
                      

                      Do you have some Panadol bills?

                      • 9. Re: FailedConfiguration while running test
                        Hussein Baghdadi Novice

                        I'm not arguing you but in your blog you say we have to use jaxb-api.jar (for JAXB 2.1)
                        But the JAXB RI 2.1.3 contains more jars: activation.jar, jaxb-xjc.jar, jaxb-impl.jar ....
                        Should I copy them to "endorsed" dir too?
                        Thanks for help.

                        • 10. Re: FailedConfiguration while running test
                          Pete Muir Master

                          I didn't need to on the sun jdk. Your best guide to this is the contents of JBoss AS 5 beta3s endorsed dir.

                          Why don't you give it a go?

                          • 11. Re: FailedConfiguration while running test
                            Hussein Baghdadi Novice

                            There is no "endorsed" directory under $JAVA_HOME/jre/lib
                            Is it ok to create it by hand?
                            Is it ok to put jaxb-api.jar under any directory in my system (as I'm passing its directory as a system property)?
                            Appreciate your patience.

                            • 12. Re: FailedConfiguration while running test
                              Pete Muir Master

                              Put the jar into any directory on your system (I can't comment on whether you should put into your $JAVA_HOME). Define the system property.

                              • 13. Re: FailedConfiguration while running test
                                Hussein Baghdadi Novice

                                I followed the instructions as your blog shows, this time I got this exception:

                                 [testng] FAILED CONFIGURATION: @BeforeClass init
                                 [testng] java.lang.RuntimeException: Unable to bootstrap:
                                 [testng] at org.jboss.embedded.Bootstrap.bootstrapURL(Bootstrap.java:167)
                                 [testng] at org.jboss.embedded.Bootstrap.bootstrap(Bootstrap.java:201)
                                 [testng] at org.jboss.embedded.Bootstrap.bootstrap(Bootstrap.java:214)
                                 [testng] at org.jboss.seam.mock.EmbeddedBootstrap.startAndDeployResources(EmbeddedBootstrap.java:11)
                                 [testng] at org.jboss.seam.mock.BaseSeamTest.startJbossEmbeddedIfNecessary(BaseSeamTest.java:1006)
                                 [testng] at org.jboss.seam.mock.BaseSeamTest.init(BaseSeamTest.java:931)
                                 [testng] at org.jboss.seam.mock.SeamTest.init(SeamTest.java:42)
                                 [testng] Caused by: org.jboss.xb.binding.JBossXBException: Failed to parse source: file:/media/sda4/Projects/ArmadaSeamProject/bootstrap/conf/bootstrap-beans.xml@50,41
                                 [testng] at org.jboss.xb.binding.parser.sax.SaxJBossXBParser.parse(SaxJBossXBParser.java:173)
                                 [testng] at org.jboss.xb.binding.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:133)
                                 [testng] at org.jboss.kernel.plugins.deployment.xml.BeanXMLDeployer.deploy(BeanXMLDeployer.java:86)
                                 [testng] at org.jboss.embedded.Bootstrap.deployBaseBootstrapUrl(Bootstrap.java:150)
                                 [testng] at org.jboss.embedded.Bootstrap.bootstrapURL(Bootstrap.java:162)
                                 [testng] ... 28 more
                                 [testng] Caused by: org.jboss.xb.binding.JBossXBRuntimeException: {urn:jboss:bean-deployer:2.0}incallback not found as a child of {urn:jboss:bean-deployer:2.0}bean
                                 [testng] at org.jboss.xb.binding.sunday.unmarshalling.SundayContentHandler.startElement(SundayContentHandler.java:283)
                                 [testng] at org.jboss.xb.binding.parser.sax.SaxJBossXBParser$DelegatingContentHandler.startElement(SaxJBossXBParser.java:381)
                                 [testng] at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source)
                                 [testng] at org.apache.xerces.parsers.AbstractXMLDocumentParser.emptyElement(Unknown Source)
                                 [testng] at org.apache.xerces.xinclude.XIncludeHandler.emptyElement(Unknown Source)
                                 [testng] at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
                                 [testng] at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
                                 [testng] at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
                                 [testng] at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
                                 [testng] at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
                                 [testng] at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
                                 [testng] at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
                                 [testng] at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
                                 [testng] at org.jboss.xb.binding.parser.sax.SaxJBossXBParser.parse(SaxJBossXBParser.java:169)
                                 [testng] ... 32 more
                                 [testng] ... Removed 22 stack frames
                                 [testng] SKIPPED CONFIGURATION: @BeforeMethod begin
                                 [testng] SKIPPED CONFIGURATION: @AfterMethod end
                                 [testng] SKIPPED CONFIGURATION: @AfterClass cleanup
                                 [testng] SKIPPED: siimulateBijection
                                 [testng]
                                


                                • 14. Re: FailedConfiguration while running test
                                  Pete Muir Master

                                  Try with Seam 2.0.1.CR1/CR2