felix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rickh...@apache.org
Subject svn commit: r1033554 - /felix/trunk/framework/src/main/java/org/apache/felix/framework/ServiceRegistry.java
Date Wed, 10 Nov 2010 16:05:12 GMT
Author: rickhall
Date: Wed Nov 10 16:05:12 2010
New Revision: 1033554

URL: http://svn.apache.org/viewvc?rev=1033554&view=rev
Log:
Throw ServiceException and return null for service factory circularity. (FELIX-2693)

Modified:
    felix/trunk/framework/src/main/java/org/apache/felix/framework/ServiceRegistry.java

Modified: felix/trunk/framework/src/main/java/org/apache/felix/framework/ServiceRegistry.java
URL: http://svn.apache.org/viewvc/felix/trunk/framework/src/main/java/org/apache/felix/framework/ServiceRegistry.java?rev=1033554&r1=1033553&r2=1033554&view=diff
==============================================================================
--- felix/trunk/framework/src/main/java/org/apache/felix/framework/ServiceRegistry.java (original)
+++ felix/trunk/framework/src/main/java/org/apache/felix/framework/ServiceRegistry.java Wed
Nov 10 16:05:12 2010
@@ -246,8 +246,10 @@ public class ServiceRegistry
                 // We don't allow cycles when we call out to the service factory.
                 if (o.equals(Thread.currentThread()))
                 {
-                    throw new IllegalStateException(
-                        "ServiceFactory.getService() resulted in a cycle.");
+                    throw new ServiceException(
+                        "ServiceFactory.getService() resulted in a cycle.",
+                        ServiceException.FACTORY_ERROR,
+                        null);
                 }
 
                 // Otherwise, wait for it to be freed.



Mime
View raw message