[
https://issues.apache.org/jira/browse/KARAF-5384?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16173680#comment-16173680
]
Seth Leger commented on KARAF-5384:
-----------------------------------
Here's the output of {{feature:install -t -v mina}} that shows the {{mina}}
installation triggering a {{org.apache.sshd.core}} refresh, which cascades to
{{jline}} and then to the rest of the core bundles:
{noformat}
karaf@root()> feature:install -t -v mina
Adding features: mina/[2.0.16,2.0.16]
Changes to perform:
Region: root
Bundles to install:
mvn:org.apache.mina/mina-core/2.0.16
Bundles to refresh:
org.apache.karaf.bundle.blueprintstate/4.1.2 (Wired to
org.apache.karaf.bundle.core/4.1.2 which is being refreshed)
org.apache.karaf.bundle.core/4.1.2 (Wired to
org.apache.karaf.shell.core/4.1.2 which is being refreshed)
org.apache.karaf.config.core/4.1.2 (Wired to
org.apache.karaf.shell.core/4.1.2 which is being refreshed)
org.apache.karaf.deployer.kar/4.1.2 (Wired to
org.apache.karaf.kar.core/4.1.2 which is being refreshed)
org.apache.karaf.diagnostic.core/4.1.2 (Wired to
org.apache.karaf.shell.core/4.1.2 which is being refreshed)
org.apache.karaf.event/4.1.2 (Wired to org.apache.karaf.shell.core/4.1.2
which is being refreshed)
org.apache.karaf.features.command/4.1.2 (Wired to
org.apache.karaf.shell.core/4.1.2 which is being refreshed)
org.apache.karaf.instance.core/4.1.2 (Wired to
org.apache.karaf.features.command/4.1.2 which is being refreshed)
org.apache.karaf.jaas.command/4.1.2 (Wired to
org.apache.karaf.shell.core/4.1.2 which is being refreshed)
org.apache.karaf.kar.core/4.1.2 (Wired to
org.apache.karaf.features.command/4.1.2 which is being refreshed)
org.apache.karaf.log.core/4.1.2 (Wired to org.apache.karaf.shell.core/4.1.2
which is being refreshed)
org.apache.karaf.package.core/4.1.2 (Wired to
org.apache.karaf.shell.core/4.1.2 which is being refreshed)
org.apache.karaf.service.core/4.1.2 (Wired to
org.apache.karaf.shell.core/4.1.2 which is being refreshed)
org.apache.karaf.shell.commands/4.1.2 (Wired to org.jline/3.4.0 which is
being refreshed)
org.apache.karaf.shell.console/4.1.2 (Wired to
org.apache.karaf.shell.core/4.1.2 which is being refreshed)
org.apache.karaf.shell.core/4.1.2 (Wired to org.jline/3.4.0 which is being
refreshed)
org.apache.karaf.shell.ssh/4.1.2 (Wired to
org.apache.karaf.shell.core/4.1.2 which is being refreshed)
org.apache.karaf.system.core/4.1.2 (Wired to
org.apache.karaf.shell.core/4.1.2 which is being refreshed)
org.apache.sshd.core/1.6.0 (Should be wired to: org.apache.mina.core/2.0.16
(through [org.apache.sshd.core/1.6.0] osgi.wiring.package;
filter:="(&(osgi.wiring.package=org.apache.mina.core)(version>=2.0.0)(!(version>=3.0.0)))";
resolution:=optional))
org.jline/3.4.0 (Wired to org.apache.sshd.core/1.6.0 which is being
refreshed)
{noformat}
> Optional dependencies in MINA SSHD Core cause system bundle refreshes
> ---------------------------------------------------------------------
>
> Key: KARAF-5384
> URL: https://issues.apache.org/jira/browse/KARAF-5384
> Project: Karaf
> Issue Type: Bug
> Components: karaf-core
> Affects Versions: 4.1.0, 4.1.1, 4.1.2
> Environment: Fedora Linux
> Reporter: Seth Leger
> Priority: Critical
> Fix For: 4.1.3
>
>
> In similar fashion to KARAF-5251, if you install any feature in Karaf that
> includes:
> - Apache MINA
> - bouncycastle
> - net.i2p.crypto
> it will cause the MINA SSHD Core bundle to refresh, which in turn refreshes
> most of the core framework bundles. This has a variety of bad effects
> including:
> - Terminating the current SSH session
> - Terminating subsequent feature installations
> This is more severe than KARAF-5251 because these libraries are not part of
> the core Karaf distro so it is not possible to add them to
> {{startup.properties}} without first repackaging Karaf to contain the desired
> bundles in the {{/system}} directory.
> This also makes testing any Karaf feature that contains MINA, bouncycastle,
> or net.i2p.crypto impossible in Pax Exam (unless you use
> org.apache.karaf.features.FeaturesService.Option.NoAutoRefreshBundles or
> feature:install -r) because the refresh invalidates @Inject references in
> your test as the core bundles are refreshed.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)