Author: bdelacretaz
Date: Thu Nov 13 09:30:24 2008
New Revision: 713758
URL: http://svn.apache.org/viewvc?rev=713758&view=rev
Log:
SLING-731 - Active bundles queue must be reprocessed if bundle.start() fails
Modified:
incubator/sling/trunk/extensions/jcrinstall/src/main/java/org/apache/sling/jcr/jcrinstall/osgi/impl/BundleResourceProcessor.java
Modified:
incubator/sling/trunk/extensions/jcrinstall/src/main/java/org/apache/sling/jcr/jcrinstall/osgi/impl/BundleResourceProcessor.java
URL:
http://svn.apache.org/viewvc/incubator/sling/trunk/extensions/jcrinstall/src/main/java/org/apache/sling/jcr/jcrinstall/osgi/impl/BundleResourceProcessor.java?rev=713758&r1=713757&r2=713758&view=diff
==============================================================================
---
incubator/sling/trunk/extensions/jcrinstall/src/main/java/org/apache/sling/jcr/jcrinstall/osgi/impl/BundleResourceProcessor.java
(original)
+++
incubator/sling/trunk/extensions/jcrinstall/src/main/java/org/apache/sling/jcr/jcrinstall/osgi/impl/BundleResourceProcessor.java
Thu Nov 13 09:30:24 2008
@@ -382,13 +382,18 @@
try {
bundle.start();
} catch (BundleException be) {
- log.error("Failed starting Bundle {}/{}",
- bundle.getSymbolicName(), bundle.getBundleId());
+ log.error("Failed to start Bundle "
+ + bundle.getSymbolicName() + "/" + bundle.getBundleId()
+ + ", rescheduling for start"
+ ,be);
// add the failed bundle to the activeBundles list
- // to start them after the next refresh
+ // to start, and trigger a refresh - the exception might
+ // be caused by a missing dependency that is in the queue,
+ // so we want to refresh even if no new bundles were added
synchronized (activeBundles) {
activeBundles.add(bundleId);
+ needsRefresh = true;
}
}
}