felix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pde...@apache.org
Subject svn commit: r1574538 - /felix/sandbox/pderop/dependencymanager-prototype/dm/src/dm/impl/DependencyImpl.java
Date Wed, 05 Mar 2014 15:43:37 GMT
Author: pderop
Date: Wed Mar  5 15:43:36 2014
New Revision: 1574538

URL: http://svn.apache.org/r1574538
Log:
Committed a proposed patch in addDependency, which seems to make ServiceDependencyInjectionTest
passing OK.


Modified:
    felix/sandbox/pderop/dependencymanager-prototype/dm/src/dm/impl/DependencyImpl.java

Modified: felix/sandbox/pderop/dependencymanager-prototype/dm/src/dm/impl/DependencyImpl.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-prototype/dm/src/dm/impl/DependencyImpl.java?rev=1574538&r1=1574537&r2=1574538&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-prototype/dm/src/dm/impl/DependencyImpl.java (original)
+++ felix/sandbox/pderop/dependencymanager-prototype/dm/src/dm/impl/DependencyImpl.java Wed
Mar  5 15:43:36 2014
@@ -4,8 +4,8 @@ import java.util.Dictionary;
 import java.util.Iterator;
 import java.util.concurrent.ConcurrentSkipListSet;
 
-import dm.ComponentDependencyDeclaration;
 import dm.Dependency;
+import dm.admin.ComponentDependencyDeclaration;
 import dm.context.ComponentContext;
 import dm.context.DependencyContext;
 import dm.context.Event;
@@ -96,7 +96,10 @@ public class DependencyImpl implements D
 			}
 			m_component.updateInstance(this);
 		}
-		m_component.handleChange();
+		if (isRequired()) {
+			// Only required dependencies may change state. 
+			m_component.handleChange();
+		}
 	}
 
 	protected void changeDependency(Event e) {



Mime
View raw message