From 4f1c083dd5892997e8fc08aae106c5aa6e622b27 Mon Sep 17 00:00:00 2001 From: slaws Date: Fri, 20 Nov 2009 13:39:36 +0000 Subject: Don't search for META-INF/services in the 1.x bundle I've been playing with. git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@882545 13f79535-47bb-0310-9956-ffa450edef68 --- .../sca/extensibility/equinox/EquinoxServiceDiscoverer.java | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'java') diff --git a/java/sca/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoverer.java b/java/sca/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoverer.java index 2b3e087e52..593fdcd4cf 100644 --- a/java/sca/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoverer.java +++ b/java/sca/modules/extensibility-equinox/src/main/java/org/apache/tuscany/sca/extensibility/equinox/EquinoxServiceDiscoverer.java @@ -185,9 +185,15 @@ public class EquinoxServiceDiscoverer implements ServiceDiscoverer { serviceName = "META-INF/services/" + serviceName; Set visited = new HashSet(); + //System.out.println(">>>> getServiceDeclarations()"); for (Bundle bundle : context.getBundles()) { - if (bundle.getBundleId() == 0 || bundle.getHeaders().get(Constants.FRAGMENT_HOST) != null) { + if (bundle.getBundleId() == 0 || + bundle.getSymbolicName().startsWith("1.x-osgi-bundle") || + bundle.getHeaders().get(Constants.FRAGMENT_HOST) != null) { // Skip system bundle as it has access to the application classloader + // Skip the 1.x runtime bundle as this has 1.x services in it + // For testing running 1.x and 2.x in same VM. + // Don't know what final form will be yet. // Skip bundle fragments too continue; } -- cgit v1.2.3