I've created a subsystem feature and one of its constituent bundles has
a dependency to org.apache.felix.bundlerepository.
Manifest-Version: 1.0
Subsystem-Localization: OSGI-INF/l10n/subsystem
Subsystem-Content: br.com.c8tech.c8osgi.api;type=osgi.bundle;version="
[0.1.1.20180814222355,0.1.1.20180814222355]";resolution:=mandatory, b
r.com.c8tech.c8osgi.lib;type=osgi.bundle;version="[0.1.1.201808142223
55,0.1.1.20180814222355]";resolution:=mandatory, br.com.c8tech.c8osgi
.lib.cm;type=osgi.bundle;version="[0.1.1.20180814222355,0.1.1.2018081
4222355]";resolution:=mandatory, br.com.c8tech.c8osgi.spi;type=osgi.b
undle;version="[0.1.1.20180814222355,0.1.1.20180814222355]";resolutio
n:=mandatory
Subsystem-Version: 0.1.1.qualifier
Subsystem-SymbolicName: br.com.c8tech.c8osgi.esa
Subsystem-Type: osgi.subsystem.feature;provision-policy:=rejectDepende
ncies
Subsystem-ManifestVersion: 1.0.0
As org.apache.felix.bundlerepository is a dependency of Aries Subsystems
it is installed and activated before Subsystem is activated.
The error is because, some how, Aries Subsystems is computing the
*org.apache.felix.bundlerepository* as an instalable resource and not as
a shared one.
When I tried to install my .esa file I'm receiving this error:
19:51:40.150|bootstrap|ERROR|Failure while installing
subsystem|b.c.c.c.b.ComponentCommandKernelBootstrap||b.c.c.c.b.ComponentCommandKernelBootstrap@513[pipe-c8osgi:install]
org.osgi.service.subsystem.SubsystemException:
org.osgi.framework.BundleException: *A bundle is already installed
with the name "org.apache.felix.bundlerepository" and version "2.0.10"*
at
org.apache.aries.subsystem.core.internal.BundleResourceInstaller.install(BundleResourceInstaller.java:183)
at
org.apache.aries.subsystem.core.internal.InstallDependencies.install(InstallDependencies.java:16)
at
org.apache.aries.subsystem.core.internal.SubsystemResourceInstaller.installAriesSubsystem(SubsystemResourceInstaller.java:87)
at
org.apache.aries.subsystem.core.internal.SubsystemResourceInstaller.install(SubsystemResourceInstaller.java:36)
at
org.apache.aries.subsystem.core.internal.InstallAction.run(InstallAction.java:83)
at
org.apache.aries.subsystem.core.internal.InstallAction.run(InstallAction.java:27)
at java.security.AccessController.doPrivileged(Native Method)
at
org.apache.aries.subsystem.core.internal.BasicSubsystem.install(BasicSubsystem.java:677)
at
org.apache.aries.subsystem.core.internal.BasicSubsystem.install(BasicSubsystem.java:730)
at
org.apache.aries.subsystem.core.internal.BasicSubsystem.install(BasicSubsystem.java:304)
at
org.apache.aries.subsystem.core.internal.BasicSubsystem.install(BasicSubsystem.java:71)
at
br.com.c8tech.c8osgi.bootstrap.ComponentCommandKernelBootstrap.deploySubsystem(ComponentCommandKernelBootstrap.java:263)
at
br.com.c8tech.c8osgi.bootstrap.ComponentCommandKernelBootstrap.requestSubsystemArchivesDeployment(ComponentCommandKernelBootstrap.java:508)
at
br.com.c8tech.c8osgi.bootstrap.ComponentCommandKernelBootstrap.install(ComponentCommandKernelBootstrap.java:304)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at
org.apache.felix.gogo.runtime.Reflective.invoke(Reflective.java:139)
at
org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:91)
at org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:599)
at
org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:526)
at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:415)
at org.apache.felix.gogo.runtime.Pipe.doCall(Pipe.java:416)
at org.apache.felix.gogo.runtime.Pipe.call(Pipe.java:229)
at org.apache.felix.gogo.runtime.Pipe.call(Pipe.java:59)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: org.osgi.framework.BundleException: A bundle is already
installed with the name "org.apache.felix.bundlerepository" and
version "2.0.10"
at
org.eclipse.osgi.container.ModuleContainer.install(ModuleContainer.java:294)
at org.eclipse.osgi.storage.Storage.install(Storage.java:658)
at
org.eclipse.osgi.internal.framework.BundleContextImpl.installBundle(BundleContextImpl.java:146)
at
org.eclipse.equinox.internal.region.BundleIdBasedRegion.installBundle0(BundleIdBasedRegion.java:117)
at
org.eclipse.equinox.internal.region.BundleIdBasedRegion.installBundleAtLocation(BundleIdBasedRegion.java:97)
at
org.apache.aries.subsystem.core.internal.BundleResourceInstaller.installBundle(BundleResourceInstaller.java:198)
at
org.apache.aries.subsystem.core.internal.BundleResourceInstaller.install(BundleResourceInstaller.java:180)
... 29 common frames omitted
Anyone have any idea what is going wrong here?
thanks,
Cristiano