Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFred Bricon2015-06-25 15:48:02 -0400
committerFred Bricon2015-06-25 19:02:25 -0400
commit7bb2bbb90057076ad1725cbc3791370caef68327 (patch)
tree1eb76ace02b14d61610d37a177c4e3e77ea91262
parenta0d6a46dc560e1f41c3a3a767a725b169cdd6a41 (diff)
downloadm2e-core-7bb2bbb90057076ad1725cbc3791370caef68327.tar.gz
m2e-core-7bb2bbb90057076ad1725cbc3791370caef68327.tar.xz
m2e-core-7bb2bbb90057076ad1725cbc3791370caef68327.zip
471038 : fix project configurator sortreleases/1.6/1.6.1.20150625-2338
Change-Id: I1b656cc41c7160f9936ab765da6cfae914d4b391 Signed-off-by: Fred Bricon <fbricon@gmail.com>
-rw-r--r--org.eclipse.m2e.core/src/org/eclipse/m2e/core/internal/lifecyclemapping/ProjectConfigurationElementSorter.java16
1 files changed, 12 insertions, 4 deletions
diff --git a/org.eclipse.m2e.core/src/org/eclipse/m2e/core/internal/lifecyclemapping/ProjectConfigurationElementSorter.java b/org.eclipse.m2e.core/src/org/eclipse/m2e/core/internal/lifecyclemapping/ProjectConfigurationElementSorter.java
index 2df199ab..33a6b1b7 100644
--- a/org.eclipse.m2e.core/src/org/eclipse/m2e/core/internal/lifecyclemapping/ProjectConfigurationElementSorter.java
+++ b/org.eclipse.m2e.core/src/org/eclipse/m2e/core/internal/lifecyclemapping/ProjectConfigurationElementSorter.java
@@ -169,10 +169,18 @@ public class ProjectConfigurationElementSorter {
continue;
}
- List<String> children = fullDag.getChildLabels(id);
- if(children == null || children.isEmpty()) {
- //found primary configurator
- //get secondaries now
+ List<String> predecessors = fullDag.getChildLabels(id);
+
+ boolean addAsPrimary = true;
+ if(predecessors != null && !predecessors.isEmpty()) {
+ for(String p : predecessors) {
+ if(configuratorIds.contains(p)) {
+ addAsPrimary = false;
+ break;
+ }
+ }
+ }
+ if(addAsPrimary) {
Set<String> secondaries = new LinkedHashSet<>();
getDependents(id, fullDag, secondaries);
primaryConfigurators.put(id, new ArrayList<>(secondaries));

Back to the top