X-Git-Url: http://git.argeo.org/?a=blobdiff_plain;ds=sidebyside;f=runtime%2Forg.argeo.slc.support.osgi%2Fsrc%2Fmain%2Fjava%2Forg%2Fargeo%2Fslc%2Fosgi%2Fbuild%2FOsgiRuntimeModularDistribution.java;fp=runtime%2Forg.argeo.slc.support.osgi%2Fsrc%2Fmain%2Fjava%2Forg%2Fargeo%2Fslc%2Fosgi%2Fbuild%2FOsgiRuntimeModularDistribution.java;h=7f3b49a381867914c9b35b0f2b3bbab2b789d7a4;hb=60b5c14f8a0c092e40090b23647fa15601b0c822;hp=1c68cf5c356917a33a30109e8d6231d56f99e80f;hpb=d9a1477429609a088714e91fb35b6ce8c5c383a1;p=gpl%2Fargeo-slc.git diff --git a/runtime/org.argeo.slc.support.osgi/src/main/java/org/argeo/slc/osgi/build/OsgiRuntimeModularDistribution.java b/runtime/org.argeo.slc.support.osgi/src/main/java/org/argeo/slc/osgi/build/OsgiRuntimeModularDistribution.java index 1c68cf5c3..7f3b49a38 100644 --- a/runtime/org.argeo.slc.support.osgi/src/main/java/org/argeo/slc/osgi/build/OsgiRuntimeModularDistribution.java +++ b/runtime/org.argeo.slc.support.osgi/src/main/java/org/argeo/slc/osgi/build/OsgiRuntimeModularDistribution.java @@ -28,14 +28,20 @@ public class OsgiRuntimeModularDistribution extends for (Bundle bundle : getBundleContext().getBundles()) { OsgiBundle osgiBundle = new OsgiBundle(bundle); - String location = bundle.getLocation(); - if (location.startsWith("reference:file:")) - location = location.substring("reference:".length()); + String originalLocation = bundle.getLocation(); + String location = originalLocation; + if (originalLocation.startsWith("reference:file:")) + location = originalLocation.substring("reference:".length()); + try { URL url = new URL(location); Resource res = resourceLoader.getResource(url.toString()); distributions.put(osgiBundle, new VersionedResourceDistribution(osgiBundle, res)); + + if (log.isTraceEnabled()) + log.debug("Added url " + url + " from original location " + + originalLocation); } catch (Exception e) { log.warn("Cannot interpret location " + location + " of bundle " + bundle + ": " + e);