geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gno...@apache.org
Subject svn commit: r781084 - in /geronimo/sandbox/blueprint: blueprint-api/src/main/java/org/osgi/service/blueprint/container/ blueprint-core/src/main/java/org/apache/geronimo/blueprint/container/
Date Tue, 02 Jun 2009 17:14:46 GMT
Author: gnodet
Date: Tue Jun  2 17:14:46 2009
New Revision: 781084

URL: http://svn.apache.org/viewvc?rev=781084&view=rev
Log:
Move close to the blueprint api for ServiceUnavailableException

Modified:
    geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java
    geronimo/sandbox/blueprint/blueprint-core/src/main/java/org/apache/geronimo/blueprint/container/RefCollectionRecipe.java
    geronimo/sandbox/blueprint/blueprint-core/src/main/java/org/apache/geronimo/blueprint/container/ReferenceRecipe.java

Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java?rev=781084&r1=781083&r2=781084&view=diff
==============================================================================
--- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java
(original)
+++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java
Tue Jun  2 17:14:46 2009
@@ -21,19 +21,13 @@
  */
 public class ServiceUnavailableException extends RuntimeException {
     
-    private Class serviceType;
     private String filter;
 
-    public ServiceUnavailableException(String message, Class serviceType, String filter)
{
+    public ServiceUnavailableException(String message, String filter) {
         super(message);
-        this.serviceType = serviceType;
         this.filter = filter;
     }
     
-    public Class getServiceType() {
-        return this.serviceType;
-    }
-    
     public String getFilter() {
         return this.filter;
     }

Modified: geronimo/sandbox/blueprint/blueprint-core/src/main/java/org/apache/geronimo/blueprint/container/RefCollectionRecipe.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-core/src/main/java/org/apache/geronimo/blueprint/container/RefCollectionRecipe.java?rev=781084&r1=781083&r2=781084&view=diff
==============================================================================
--- geronimo/sandbox/blueprint/blueprint-core/src/main/java/org/apache/geronimo/blueprint/container/RefCollectionRecipe.java
(original)
+++ geronimo/sandbox/blueprint/blueprint-core/src/main/java/org/apache/geronimo/blueprint/container/RefCollectionRecipe.java
Tue Jun  2 17:14:46 2009
@@ -32,7 +32,6 @@
 import java.util.Set;
 import java.util.concurrent.Callable;
 
-import net.sf.cglib.proxy.Dispatcher;
 import org.apache.geronimo.blueprint.ExtendedBlueprintContainer;
 import org.apache.geronimo.blueprint.ExtendedRefCollectionMetadata;
 import org.apache.geronimo.blueprint.di.Recipe;
@@ -235,7 +234,7 @@
 
         public synchronized Object call() throws Exception {
             if (reference == null) {
-                throw new ServiceUnavailableException("Service is unavailable", null, null);
+                throw new ServiceUnavailableException("Service is unavailable", null);
             }
             if (service == null) {
                 service = reference.getBundle().getBundleContext().getService(reference);

Modified: geronimo/sandbox/blueprint/blueprint-core/src/main/java/org/apache/geronimo/blueprint/container/ReferenceRecipe.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-core/src/main/java/org/apache/geronimo/blueprint/container/ReferenceRecipe.java?rev=781084&r1=781083&r2=781084&view=diff
==============================================================================
--- geronimo/sandbox/blueprint/blueprint-core/src/main/java/org/apache/geronimo/blueprint/container/ReferenceRecipe.java
(original)
+++ geronimo/sandbox/blueprint/blueprint-core/src/main/java/org/apache/geronimo/blueprint/container/ReferenceRecipe.java
Tue Jun  2 17:14:46 2009
@@ -21,7 +21,6 @@
 import java.lang.reflect.Type;
 import java.util.concurrent.Callable;
 
-import net.sf.cglib.proxy.Dispatcher;
 import org.apache.geronimo.blueprint.ExtendedBlueprintContainer;
 import org.apache.geronimo.blueprint.di.Recipe;
 import org.apache.geronimo.blueprint.utils.ConversionUtils;
@@ -46,7 +45,6 @@
 public class ReferenceRecipe extends AbstractServiceReferenceRecipe {
 
     private final ReferenceMetadata metadata;
-    private Class proxyClass;
     private Object proxy;
 
     private volatile ServiceReference trackedServiceReference;
@@ -66,7 +64,6 @@
         try {
             // Create the proxy
             proxy = createProxy(new ServiceDispatcher(), this.metadata.getInterfaceNames());
-            proxyClass = proxy.getClass();
 
             // Add partially created proxy to the context
             addObject(proxy, true);
@@ -146,9 +143,9 @@
             }
             if (trackedServiceReference == null) {
                 if (isStarted()) {
-                    throw new ServiceUnavailableException("Timeout expired when waiting for
OSGi service", proxyClass.getSuperclass(), getOsgiFilter());
+                    throw new ServiceUnavailableException("Timeout expired when waiting for
OSGi service", getOsgiFilter());
                 } else {
-                    throw new ServiceUnavailableException("Service tracker is stopped", proxyClass.getSuperclass(),
getOsgiFilter());
+                    throw new ServiceUnavailableException("Service tracker is stopped", getOsgiFilter());
                 }
             }
             if (trackedService == null) {



Mime
View raw message