summaryrefslogtreecommitdiffstats
path: root/branches/sca-equinox
diff options
context:
space:
mode:
Diffstat (limited to 'branches/sca-equinox')
-rw-r--r--branches/sca-equinox/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoverer.java7
-rw-r--r--branches/sca-equinox/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoveryActivator.java5
-rw-r--r--branches/sca-equinox/modules/extensibility/src/main/java/org/apache/tuscany/sca/extensibility/ServiceDiscovery.java13
3 files changed, 3 insertions, 22 deletions
diff --git a/branches/sca-equinox/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoverer.java b/branches/sca-equinox/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoverer.java
index 8c07caf0e4..3d33782a29 100644
--- a/branches/sca-equinox/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoverer.java
+++ b/branches/sca-equinox/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoverer.java
@@ -298,11 +298,4 @@ public class EquinoxServiceDiscoverer implements ServiceDiscoverer {
return descriptors;
}
- public Object newFactoryClassInstance(String name) throws SecurityException, NoSuchMethodException, InvocationTargetException, IllegalAccessException, ClassNotFoundException {
- Class<?> factoryClass = Class.forName(name, false, getClass().getClassLoader());
- Method newInstanceMethod = factoryClass.getMethod("newInstance");
- Object factory = newInstanceMethod.invoke(null);
- return factory;
- }
-
}
diff --git a/branches/sca-equinox/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoveryActivator.java b/branches/sca-equinox/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoveryActivator.java
index 1cb1d09f8d..0c7eaec70b 100644
--- a/branches/sca-equinox/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoveryActivator.java
+++ b/branches/sca-equinox/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoveryActivator.java
@@ -28,16 +28,15 @@ import org.osgi.framework.BundleContext;
/**
* The Bundle Activator that creates the Equinox-based service discoverer
*
- * @version $Rev: $ $Date: $
+ * @version $Rev$ $Date$
*/
public class EquinoxServiceDiscoveryActivator implements BundleActivator {
private static Logger logger = Logger.getLogger(EquinoxServiceDiscoveryActivator.class.getName());
public void start(BundleContext context) throws Exception {
- logger.info("Installing service discovery");
EquinoxServiceDiscoverer discoverer = new EquinoxServiceDiscoverer(context);
ServiceDiscovery.getInstance().setServiceDiscoverer(discoverer);
- logger.info("Installed service discovery");
+ logger.info("Equinox-based service discoverer is now configured.");
}
public void stop(BundleContext context) throws Exception {
diff --git a/branches/sca-equinox/modules/extensibility/src/main/java/org/apache/tuscany/sca/extensibility/ServiceDiscovery.java b/branches/sca-equinox/modules/extensibility/src/main/java/org/apache/tuscany/sca/extensibility/ServiceDiscovery.java
index e78cb136d3..ff8f2399df 100644
--- a/branches/sca-equinox/modules/extensibility/src/main/java/org/apache/tuscany/sca/extensibility/ServiceDiscovery.java
+++ b/branches/sca-equinox/modules/extensibility/src/main/java/org/apache/tuscany/sca/extensibility/ServiceDiscovery.java
@@ -20,8 +20,6 @@
package org.apache.tuscany.sca.extensibility;
import java.io.IOException;
-import java.security.AccessController;
-import java.security.PrivilegedAction;
import java.util.Set;
import java.util.logging.Logger;
@@ -70,16 +68,7 @@ public class ServiceDiscovery implements ServiceDiscoverer {
}
public ServiceDeclaration getFirstServiceDeclaration(final String name) throws IOException {
- // Try System property first
- String className = AccessController.doPrivileged(new PrivilegedAction<String>() {
- public String run() {
- return System.getProperty(name);
- }
- });
- if (className == null) {
- className = name;
- }
- ServiceDeclaration service = getServiceDiscoverer().getFirstServiceDeclaration(className);
+ ServiceDeclaration service = getServiceDiscoverer().getFirstServiceDeclaration(name);
return service;
}