Hide Forgot
mvn clean install throws an exception 12:38:54,818 ERROR [org.switchyard.test.SwitchYardRunner] Error while test kit startup java.lang.ExceptionInInitializerError at org.kie.scanner.embedder.MavenProjectLoader.loadMavenProject(MavenProjectLoader.java:53) at org.kie.scanner.Aether.<init>(Aether.java:44) at org.kie.scanner.Aether.<clinit>(Aether.java:35) at org.kie.scanner.MavenRepository.<clinit>(MavenRepository.java:30) at org.kie.scanner.ArtifactResolver.getMavenProjectForGAV(ArtifactResolver.java:78) at org.kie.scanner.ArtifactResolver.getResolverFor(ArtifactResolver.java:56) at org.kie.scanner.MavenClassLoaderResolver.getClassLoader(MavenClassLoaderResolver.java:48) at org.drools.compiler.kie.builder.impl.KieModuleKieProject.<init>(KieModuleKieProject.java:50) at org.drools.compiler.kie.builder.impl.KieModuleKieProject.<init>(KieModuleKieProject.java:38) at org.drools.compiler.kie.builder.impl.KieBuilderImpl.buildAll(KieBuilderImpl.java:184) at org.switchyard.component.common.knowledge.session.KnowledgeBuilderSessionFactory.newBase(KnowledgeBuilderSessionFactory.java:125) at org.switchyard.component.common.knowledge.session.KnowledgeBuilderSessionFactory.<init>(KnowledgeBuilderSessionFactory.java:71) at org.switchyard.component.common.knowledge.session.KnowledgeSessionFactory.newSessionFactory(KnowledgeSessionFactory.java:117) at org.switchyard.component.common.knowledge.exchange.KnowledgeExchangeHandler.doStart(KnowledgeExchangeHandler.java:204) at org.switchyard.component.bpm.exchange.BPMExchangeHandler.doStart(BPMExchangeHandler.java:108) at org.switchyard.deploy.BaseServiceHandler.start(BaseServiceHandler.java:60) at org.switchyard.deploy.internal.Deployment.deployImplementations(Deployment.java:574) at org.switchyard.deploy.internal.Deployment.start(Deployment.java:144) at org.switchyard.test.SwitchYardTestKit.deploy(SwitchYardTestKit.java:757) at org.switchyard.test.SwitchYardTestKit.start(SwitchYardTestKit.java:177) at org.switchyard.test.SwitchYardRunner.createTest(SwitchYardRunner.java:60) at org.junit.runners.BlockJUnit4ClassRunner$1.runReflectiveCall(BlockJUnit4ClassRunner.java:244) at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) at org.junit.runners.BlockJUnit4ClassRunner.methodBlock(BlockJUnit4ClassRunner.java:241) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229) at org.junit.runners.ParentRunner.run(ParentRunner.java:309) at org.switchyard.test.SwitchYardRunner.run(SwitchYardRunner.java:85) at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252) at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141) at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189) at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165) at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85) at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115) at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75) Caused by: java.lang.RuntimeException: org.apache.maven.project.ProjectBuildingException: Some problems were encountered while processing the POMs: [FATAL] Non-resolvable parent POM for org.switchyard.quickstarts:switchyard-quickstart-parent:1.1.1-p2-redhat-2: Failure to find org.switchyard:switchyard-parent:pom:1.1.1-p2-redhat-2 in http://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced and 'parent.relativePath' points at wrong local POM @ org.switchyard.quickstarts:switchyard-quickstart-parent:1.1.1-p2-redhat-2, /home/jpechane/releases/er8/full/jboss-eap-6.1/quickstarts/switchyard/pom.xml, line 17, column 13 at org.kie.scanner.embedder.MavenProjectLoader.parseMavenPom(MavenProjectLoader.java:28) at org.kie.scanner.embedder.MavenProjectLoader$MavenProjectHolder.loadMavenProject(MavenProjectLoader.java:14) at org.kie.scanner.embedder.MavenProjectLoader$MavenProjectHolder.<clinit>(MavenProjectLoader.java:10) ... 45 more Caused by: org.apache.maven.project.ProjectBuildingException: Some problems were encountered while processing the POMs: [FATAL] Non-resolvable parent POM for org.switchyard.quickstarts:switchyard-quickstart-parent:1.1.1-p2-redhat-2: Failure to find org.switchyard:switchyard-parent:pom:1.1.1-p2-redhat-2 in http://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced and 'parent.relativePath' points at wrong local POM @ org.switchyard.quickstarts:switchyard-quickstart-parent:1.1.1-p2-redhat-2, /home/jpechane/releases/er8/full/jboss-eap-6.1/quickstarts/switchyard/pom.xml, line 17, column 13 at org.apache.maven.project.DefaultProjectBuilder.build(DefaultProjectBuilder.java:363) at org.kie.scanner.embedder.MavenEmbedder.buildProjects(MavenEmbedder.java:370) at org.kie.scanner.embedder.MavenEmbedder.readProjects(MavenEmbedder.java:354) at org.kie.scanner.embedder.MavenEmbedder.readProject(MavenEmbedder.java:347) at org.kie.scanner.embedder.MavenProjectLoader.parseMavenPom(MavenProjectLoader.java:26) ... 47 more
David - this is actually an issue with the Maven environment during test and not at runtime, so the kie-ci module and Maven libs are not a factor. I believe this is due to the fact that Drools only picks up the user's environment from settings.xml and does not respect the current profile as passed in via -P. Let me explain a bit more. Here are the important lines that are obscured in the long stack trace: [FATAL] Non-resolvable parent POM for org.switchyard.quickstarts:switchyard-quickstart-parent:1.1.1-p2-redhat-2: Failure to find org.switchyard:switchyard-parent:pom:1.1.1-p2-redhat-2 in http://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced ... I get the same error if I run the project build locally with an offline repo. The settings to point to this local repo are in a profile in my settings.xml, so I will build the project with "mvn -Pfsw clean package". *However*, if i make the 'fsw' profile activeByDefault in my settings.xml instead of passing the profile from the command-line, then everything works. There's nothing we can do about this from a SY POV. We need to evaluate if/when the Drools team will address the issue of respecting profile activation via command-line. Perhaps this is already fixed and simply requires a refresh of the Drools version we include in FSW. Without that, then we are looking at documenting this as a requirement for the user to have the FSW maven repo in a profile that's active by default.
Proposed doc text: When building the bpm-service quickstart, the FSW Maven repository must be contained in a profile in the user's settings.xml and that profile must be marked as <activeByDefault>true</activeByDefault>. For more information please consult section 4.2.3.5 "Settings.xml and Remote Repository Setup" in the BRMS documentation [1]. http://docs.jboss.org/drools/release/6.0.1.Final/drools-docs/html/KIEChapter.html#KIEDeployingSection NOTE TO DOCS : the above link is for community documentation. I'm not sure where this section lives in the BRMS product documentation, but we may want to link to that instead of community.