-
Bug
-
Resolution: Postponed
-
Critical
-
None
Here is the phase definiton I use:
<com.tikal.jenkins.plugins.multijob.MultiJobBuilder> <phaseName>Develop</phaseName> <continuationCondition>SUCCESSFUL</continuationCondition> <phaseJobs> <com.tikal.jenkins.plugins.multijob.PhaseJobsConfig> <jobName>delphi-platform-Fast-DSL</jobName> <currParams>true</currParams> <exposedSCM>true</exposedSCM> <disableJob>false</disableJob> <killPhaseOnJobResultCondition>UNSTABLE</killPhaseOnJobResultCondition> <abortAllJob>true</abortAllJob> <configs class="java.util.Collections$EmptyList"></configs> <buildOnlyIfSCMChanges>true</buildOnlyIfSCMChanges> </com.tikal.jenkins.plugins.multijob.PhaseJobsConfig> </phaseJobs> </com.tikal.jenkins.plugins.multijob.MultiJobBuilder>
Notice it has killPhaseOnJobResultCondition=UNSTABLE and continuationCondition=SUCCESSFUL
However one run skipped the subjob execution even though it's result was FAILURE
12:45:06 [poll] Latest remote head revision on refs/heads/develop is: 9daf17ad24fd88d98585f0f89e96c416d532f4ec - already built by 359 12:45:06 >> Job status: [delphi-platform-Fast-DSL] subjob has no changes since last build.
You can see the result and actions for said job here: curl $JENKINS_URL'job/delphi-platform-Fast-DSL/359/api/xml?xpath=//*[local-name()=%27result%27%20or%20local-name()=%27action%27]&wrapper=wrapper'
<wrapper> <action _class="hudson.model.CauseAction"> <cause _class="hudson.triggers.SCMTrigger$SCMTriggerCause"> <shortDescription>Started by an SCM change</shortDescription> </cause> </action> <action></action> <action></action> <action></action> <action></action> <action _class="hudson.plugins.git.util.BuildData"> <buildsByBranchName> <refsremotesorigindevelop _class="hudson.plugins.git.util.Build"> <buildNumber>359</buildNumber> <marked> <SHA1>9daf17ad24fd88d98585f0f89e96c416d532f4ec</SHA1> <branch> <SHA1>9daf17ad24fd88d98585f0f89e96c416d532f4ec</SHA1> <name>refs/remotes/origin/develop</name> </branch> </marked> <revision> <SHA1>9daf17ad24fd88d98585f0f89e96c416d532f4ec</SHA1> <branch> <SHA1>9daf17ad24fd88d98585f0f89e96c416d532f4ec</SHA1> <name>refs/remotes/origin/develop</name> </branch> </revision> </refsremotesorigindevelop> </buildsByBranchName> <lastBuiltRevision> <SHA1>9daf17ad24fd88d98585f0f89e96c416d532f4ec</SHA1> <branch> <SHA1>9daf17ad24fd88d98585f0f89e96c416d532f4ec</SHA1> <name>refs/remotes/origin/develop</name> </branch> </lastBuiltRevision> <remoteUrl>git@git.acme-internal.com:delphi/delphi-platform.git</remoteUrl> <scmName></scmName> </action> <action _class="hudson.plugins.git.GitTagAction"></action> <action></action> <action _class="hudson.maven.reporters.MavenAggregatedArtifactRecord"></action> <action _class="hudson.maven.reporters.SurefireAggregatedReport"> <failCount>0</failCount> <skipCount>0</skipCount> <totalCount>227</totalCount> <urlName>testReport</urlName> </action> <action></action> <action></action> <action></action> <result>FAILURE</result> </wrapper>
Previous build was STABLE, but there were SCM changes since: curl $JENKINS_URL'job/delphi-platform-Fast-DSL/358/api/xml?xpath=//*[local-name()=%27result%27%20or%20local-name()=%27action%27]&wrapper=wrapper'
<wrapper> <action _class="hudson.model.CauseAction"> <cause _class="hudson.triggers.SCMTrigger$SCMTriggerCause"> <shortDescription>Started by an SCM change</shortDescription> </cause> </action> <action></action> <action></action> <action></action> <action></action> <action _class="hudson.plugins.git.util.BuildData"> <buildsByBranchName> <refsremotesorigindevelop _class="hudson.plugins.git.util.Build"> <buildNumber>358</buildNumber> <marked> <SHA1>55e09e648aa082a05ce1721706e60df2c81cd0a8</SHA1> <branch> <SHA1>55e09e648aa082a05ce1721706e60df2c81cd0a8</SHA1> <name>refs/remotes/origin/develop</name> </branch> </marked> <revision> <SHA1>55e09e648aa082a05ce1721706e60df2c81cd0a8</SHA1> <branch> <SHA1>55e09e648aa082a05ce1721706e60df2c81cd0a8</SHA1> <name>refs/remotes/origin/develop</name> </branch> </revision> </refsremotesorigindevelop> </buildsByBranchName> <lastBuiltRevision> <SHA1>55e09e648aa082a05ce1721706e60df2c81cd0a8</SHA1> <branch> <SHA1>55e09e648aa082a05ce1721706e60df2c81cd0a8</SHA1> <name>refs/remotes/origin/develop</name> </branch> </lastBuiltRevision> <remoteUrl>git@git.acme-internal.com:delphi/delphi-platform.git</remoteUrl> <scmName></scmName> </action> <action _class="hudson.plugins.git.GitTagAction"></action> <action></action> <action _class="hudson.maven.reporters.MavenAggregatedArtifactRecord"></action> <action _class="hudson.maven.reporters.SurefireAggregatedReport"> <failCount>0</failCount> <skipCount>0</skipCount> <totalCount>513</totalCount> <urlName>testReport</urlName> </action> <action></action> <action _class="hudson.plugins.warnings.WarningsResultAction"></action> <action _class="hudson.plugins.warnings.AggregatedWarningsResultAction"></action> <action></action> <action></action> <result>SUCCESS</result> </wrapper>
I'd expect Multijob to re-run the subjob if last build status is not SUCCESS – I even saw it happening in some cases, but it's not working here
- relates to
-
JENKINS-37650 'Build only if SCM changes' doesn't wait until the build has finished
- Closed