On releasing, release the top level component last - so that we don't end up with partial release info
This commit is contained in:
parent
f4d8ff7a53
commit
329997e982
2 changed files with 13 additions and 2 deletions
|
|
@ -658,12 +658,16 @@ class MetaInfo extends GISJsonSerialised {
|
|||
return releasemetacollection
|
||||
}
|
||||
|
||||
String componentidentifier() {
|
||||
return productinfo.productname + "_" + productinfo.subcomponentname
|
||||
}
|
||||
|
||||
Map<String, RelatedMetaInfo> releasewalkerunique(int maxdepth, String startpath = "") {
|
||||
Map<String, RelatedMetaInfo> releasemetauniquecollection = new LinkedHashMap<String, RelatedMetaInfo>()
|
||||
ArrayList<RelatedMetaInfo> releasemetacollection = new ArrayList<RelatedMetaInfo>()
|
||||
releasemetacollection = releasewalkerp(maxdepth, releasemetacollection, startpath)
|
||||
for (relatedmetainfo in releasemetacollection) {
|
||||
String uniquestring = relatedmetainfo.meta.productinfo.productname + "_" + relatedmetainfo.meta.productinfo.subcomponentname
|
||||
String uniquestring = relatedmetainfo.meta.componentidentifier()
|
||||
releasemetauniquecollection.put(uniquestring, relatedmetainfo)
|
||||
}
|
||||
return releasemetauniquecollection
|
||||
|
|
|
|||
|
|
@ -341,11 +341,18 @@ def releasehierarchy(buildmeta, String maxdepth, String otherreleasetags, String
|
|||
// Walk the meta information to a max depth, looking for artifacts to import for release
|
||||
componentReleaseInfo = buildmeta.releasewalkerunique(md)
|
||||
|
||||
def toplevelid = buildmeta.componentidentifier()
|
||||
// For each component
|
||||
for (key in componentReleaseInfo.keySet()) {
|
||||
def buildinfo = componentReleaseInfo[key]
|
||||
releasecomponent(buildinfo, otherreleasetags, dryrunpush)
|
||||
if (toplevelid != key) {
|
||||
releasecomponent(buildinfo, otherreleasetags, dryrunpush)
|
||||
}
|
||||
}
|
||||
// Do the top level last
|
||||
def toplevelbuildinfo = componentReleaseInfo[toplevelid]
|
||||
releasecomponent(toplevelbuildinfo, otherreleasetags, dryrunpush)
|
||||
|
||||
return [summarystring, markunstable, unstablereason]
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue