Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStoyan Boshev2011-11-17 14:05:22 +0000
committerStoyan Boshev2011-11-17 14:05:22 +0000
commitd4520e11e5282d4ed84732be401602aef135ee29 (patch)
treec1f5febe7dab012088c0bb5633e358292dfbe7cb
parentd6c420ff35e4ae5abb9971d9cc9db6a1535c546c (diff)
downloadrt.equinox.bundles-d4520e11e5282d4ed84732be401602aef135ee29.tar.gz
rt.equinox.bundles-d4520e11e5282d4ed84732be401602aef135ee29.tar.xz
rt.equinox.bundles-d4520e11e5282d4ed84732be401602aef135ee29.zip
Bug 360105 [DS] SCRManager waits too long to enable components
-rw-r--r--bundles/org.eclipse.equinox.ds/src/org/eclipse/equinox/internal/ds/SCRManager.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/bundles/org.eclipse.equinox.ds/src/org/eclipse/equinox/internal/ds/SCRManager.java b/bundles/org.eclipse.equinox.ds/src/org/eclipse/equinox/internal/ds/SCRManager.java
index f53b96537..6ca9b2dfd 100644
--- a/bundles/org.eclipse.equinox.ds/src/org/eclipse/equinox/internal/ds/SCRManager.java
+++ b/bundles/org.eclipse.equinox.ds/src/org/eclipse/equinox/internal/ds/SCRManager.java
@@ -645,9 +645,9 @@ public class SCRManager implements ServiceListener, SynchronousBundleListener, C
synchronized (components) {
long startTime = System.currentTimeMillis();
try {
- do {
+ while (!components.isEmpty() && (System.currentTimeMillis() - startTime < WorkThread.BLOCK_TIMEOUT)) {
components.wait(1000);
- } while (!components.isEmpty() && (System.currentTimeMillis() - startTime < WorkThread.BLOCK_TIMEOUT));
+ }
if (System.currentTimeMillis() - startTime >= WorkThread.BLOCK_TIMEOUT) {
Activator.log(null, LogService.LOG_WARNING, NLS.bind(Messages.TIMEOUT_REACHED_ENABLING_COMPONENTS, getBundleName(bundle), Integer.toString(WorkThread.BLOCK_TIMEOUT)), null);
}

Back to the top