Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Watson2016-02-18 22:24:23 +0000
committerThomas Watson2016-02-18 22:24:23 +0000
commit4fd2f05b336c91636728bb368eb70a9fa843ddcc (patch)
treeb076acbe3aa1c8894e10773325ae8c8a3bfa7f3f /bundles/org.eclipse.equinox.cm/src
parent0779ae0b4fe93a68f97175f4483fc84efd35b619 (diff)
downloadrt.equinox.bundles-4fd2f05b336c91636728bb368eb70a9fa843ddcc.tar.gz
rt.equinox.bundles-4fd2f05b336c91636728bb368eb70a9fa843ddcc.tar.xz
rt.equinox.bundles-4fd2f05b336c91636728bb368eb70a9fa843ddcc.zip
Bug 487982 - OSGi Configuration Admin does not call all applicable
Configuration Plugins Change-Id: I8471c39bc3f0ea8e7f3f6bde5400b38bd8f7c406 Signed-off-by: Thomas Watson <tjwatson@us.ibm.com>
Diffstat (limited to 'bundles/org.eclipse.equinox.cm/src')
-rw-r--r--bundles/org.eclipse.equinox.cm/src/org/eclipse/equinox/internal/cm/PluginManager.java9
1 files changed, 7 insertions, 2 deletions
diff --git a/bundles/org.eclipse.equinox.cm/src/org/eclipse/equinox/internal/cm/PluginManager.java b/bundles/org.eclipse.equinox.cm/src/org/eclipse/equinox/internal/cm/PluginManager.java
index edf5f42a..dbab045c 100644
--- a/bundles/org.eclipse.equinox.cm/src/org/eclipse/equinox/internal/cm/PluginManager.java
+++ b/bundles/org.eclipse.equinox.cm/src/org/eclipse/equinox/internal/cm/PluginManager.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2005, 2013 Cognos Incorporated, IBM Corporation and others.
+ * Copyright (c) 2005, 2016 Cognos Incorporated, IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -57,7 +57,12 @@ public class PluginManager {
private TreeSet<ServiceReference<ConfigurationPlugin>> serviceReferences = new TreeSet<ServiceReference<ConfigurationPlugin>>(new Comparator<ServiceReference<ConfigurationPlugin>>() {
public int compare(ServiceReference<ConfigurationPlugin> s1, ServiceReference<ConfigurationPlugin> s2) {
- return getRank(s1).compareTo(getRank(s2));
+ int rankCompare = getRank(s1).compareTo(getRank(s2));
+ if (rankCompare != 0) {
+ return rankCompare;
+ }
+ // we reverse the order which means services with higher service.ranking properties are called first
+ return -(s1.compareTo(s2));
}
private Integer getRank(ServiceReference<ConfigurationPlugin> ref) {

Back to the top