aries-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gno...@apache.org
Subject svn commit: r1071718 - /aries/branches/0.2-incubating-RCx/blueprint/blueprint-core/src/main/java/org/apache/aries/blueprint/container/ServiceRecipe.java
Date Thu, 17 Feb 2011 17:35:28 GMT
Author: gnodet
Date: Thu Feb 17 17:35:28 2011
New Revision: 1071718

URL: http://svn.apache.org/viewvc?rev=1071718&view=rev
Log:
[ARIES-424] Under certain circumstances, the blueprint container try to register a service
while the bundle is stopping

Modified:
    aries/branches/0.2-incubating-RCx/blueprint/blueprint-core/src/main/java/org/apache/aries/blueprint/container/ServiceRecipe.java

Modified: aries/branches/0.2-incubating-RCx/blueprint/blueprint-core/src/main/java/org/apache/aries/blueprint/container/ServiceRecipe.java
URL: http://svn.apache.org/viewvc/aries/branches/0.2-incubating-RCx/blueprint/blueprint-core/src/main/java/org/apache/aries/blueprint/container/ServiceRecipe.java?rev=1071718&r1=1071717&r2=1071718&view=diff
==============================================================================
--- aries/branches/0.2-incubating-RCx/blueprint/blueprint-core/src/main/java/org/apache/aries/blueprint/container/ServiceRecipe.java
(original)
+++ aries/branches/0.2-incubating-RCx/blueprint/blueprint-core/src/main/java/org/apache/aries/blueprint/container/ServiceRecipe.java
Thu Feb 17 17:35:28 2011
@@ -132,6 +132,10 @@ public class ServiceRecipe extends Abstr
     }
 
     public void register() {
+        int state = blueprintContainer.getBundleContext().getBundle().getState();
+        if (state != Bundle.ACTIVE && state != Bundle.STARTING) {
+            return;
+        }
         if (registered.compareAndSet(false, true)) {
             createExplicitDependencies();
             



Mime
View raw message