cleclerc Sorry for the delay in testing this – I was out of town. I was not able to get this to work using 3.0.1-beta-2. This is what I did to test using the multi_module_bundle_project test project:
I created three jenkins pipelines (one for each of the modules) that are exactly the same except for the mvn command:
- test-parent: mvn -N clean install
- test-api: mvn -f print-api/pom.xml clean install
- test-impl: mvn -f print-impl/pom.xml clean install
I then executed test-parent, test-api, and test-impl to establish the relationships in the H2 database. I then executed the test-api again expecting the test-impl pipeline to be triggered, but it did not. In the spy log for the test-api pipeline, I only see the 'bundle' artifact captured from the test-api pipeline.
node {
stage('Preparation') { git url: 'file:, branch: 'master'
}
stage('Build') {
withMaven(
maven: 'Maven') {
writeFile file: '.archive-jenkins-maven-event-spy-logs', text: ''
sh "mvn -f print-api/pom.xml clean install"
}
}
}
<ExecutionEvent type="ProjectSucceeded" class="org.apache.maven.lifecycle.internal.DefaultExecutionEvent" _time="2017-10-12 16:22:09.117">
<project baseDir="/var/jenkins_home/workspace/test-api/print-api" file="/var/jenkins_home/workspace/test-api/print-api/pom.xml" groupId="jenkins.mvn.test.bundle" name="print-api" artifactId="print-api" version="0.0.1-SNAPSHOT">
<build sourceDirectory="/var/jenkins_home/workspace/test-api/print-api/src/main/java" directory="/var/jenkins_home/workspace/test-api/print-api/target"/>
</project>
<no-execution-found/>
<artifact extension="jar" baseVersion="0.0.1-SNAPSHOT" groupId="jenkins.mvn.test.bundle" artifactId="print-api" id="jenkins.mvn.test.bundle:print-api:bundle:0.0.1-SNAPSHOT" type="bundle" version="0.0.1-SNAPSHOT" snapshot="true">
<file>/var/jenkins_home/workspace/test-api/print-api/target/print-api-0.0.1-SNAPSHOT.jar</file>
</artifact>
<attachedArtifacts/>
</ExecutionEvent>
Can you confirm that you are referring to the org.apache.felix:maven-bundle-plugin:bundle goal ?
Could you provide a sample of the usage of the maven-bundle-plugin similar to what we have https://github.com/jenkinsci/pipeline-maven-plugin/tree/master/jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects ?