cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject svn commit: r1232409 - /cxf/dosgi/trunk/dsw/cxf-dsw/src/main/java/org/apache/cxf/dosgi/dsw/service/RemoteServiceAdminInstance.java
Date Tue, 17 Jan 2012 13:40:27 GMT
Author: sergeyb
Date: Tue Jan 17 13:40:27 2012
New Revision: 1232409

URL: http://svn.apache.org/viewvc?rev=1232409&view=rev
Log:
[DOSGI-7] Removing redundant list of imported references

Modified:
    cxf/dosgi/trunk/dsw/cxf-dsw/src/main/java/org/apache/cxf/dosgi/dsw/service/RemoteServiceAdminInstance.java

Modified: cxf/dosgi/trunk/dsw/cxf-dsw/src/main/java/org/apache/cxf/dosgi/dsw/service/RemoteServiceAdminInstance.java
URL: http://svn.apache.org/viewvc/cxf/dosgi/trunk/dsw/cxf-dsw/src/main/java/org/apache/cxf/dosgi/dsw/service/RemoteServiceAdminInstance.java?rev=1232409&r1=1232408&r2=1232409&view=diff
==============================================================================
--- cxf/dosgi/trunk/dsw/cxf-dsw/src/main/java/org/apache/cxf/dosgi/dsw/service/RemoteServiceAdminInstance.java
(original)
+++ cxf/dosgi/trunk/dsw/cxf-dsw/src/main/java/org/apache/cxf/dosgi/dsw/service/RemoteServiceAdminInstance.java
Tue Jan 17 13:40:27 2012
@@ -20,7 +20,6 @@ package org.apache.cxf.dosgi.dsw.service
 
 import java.security.AccessController;
 import java.security.PrivilegedAction;
-import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Collections;
 import java.util.List;
@@ -44,8 +43,6 @@ public class RemoteServiceAdminInstance 
 
     private boolean closed = false;
 
-    private List<ImportRegistration> importedServices = new ArrayList<ImportRegistration>();
-    
     public RemoteServiceAdminInstance(BundleContext bc, RemoteServiceAdminCore core) {
         bctx = bc;
         rsaCore = core;
@@ -120,26 +117,13 @@ public class RemoteServiceAdminInstance 
                 if (closed)
                     return null;
 
-                synchronized (importedServices) {
-                    ImportRegistration ir = rsaCore.importService(epd);
-                    if (ir != null)
-                        importedServices.add(ir);
-                    return ir;
-                }
+                return rsaCore.importService(epd);
             }
         });
     }
 
     public void close() {
         closed = true;
-
-        synchronized (importedServices) {
-            LOG.info("Removing all services imported by this RSA instance");
-            for (ImportRegistration ir : importedServices) {
-                LOG.finest("Closing ImportRegistration " + ir);
-                ir.close();
-            }
-        }
     }
 
 }



Mime
View raw message