You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@aries.apache.org by jw...@apache.org on 2015/10/09 01:53:27 UTC
svn commit: r1707636 -
/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/internal/RegionUpdater.java
Author: jwross
Date: Thu Oct 8 23:53:26 2015
New Revision: 1707636
URL: http://svn.apache.org/viewvc?rev=1707636&view=rev
Log:
ARIES-1429 NullPointerException at org.apache.aries.subsystem.core.internal.WovenClassListener.modified at org.apache.aries.subsystem.core.internal.RegionUpdater.addRequirements
When processing the dynamic package imports of a bundle's woven class, if no edge if found between the subsystem containing the bundle as a constituent and the parent subsystem,
assume that an external entity is handling the dynamic imports rather than throwing an exception.
Modified:
aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/internal/RegionUpdater.java
Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/internal/RegionUpdater.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/internal/RegionUpdater.java?rev=1707636&r1=1707635&r2=1707636&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/internal/RegionUpdater.java (original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/internal/RegionUpdater.java Thu Oct 8 23:53:26 2015
@@ -57,7 +57,15 @@ public class RegionUpdater {
copy.removeRegion(tail);
tail = copy.createRegion(tail.getName());
addBundleIds(bundleIds, tail);
- addRequirements(requirements, heads.get(head.getName()));
+ RegionFilterBuilder builder = heads.get(head.getName());
+ if (builder == null) {
+ // Something outside of the subsystems implementation has
+ // deleted the edge between the parent and child subsystems.
+ // Assume the dynamic import sharing policy is being handled
+ // elsewhere. See ARIES-1429.
+ return;
+ }
+ addRequirements(requirements, builder);
addHeadRegions(heads, tail, copy);
addTailRegions(tails, tail, copy);
// Replace the current digraph.