You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@karaf.apache.org by "Guillaume Nodet (JIRA)" <ji...@apache.org> on 2017/12/14 16:47:00 UTC

[jira] [Resolved] (KARAF-5542) Installing a feature triggers restarting previous ones

     [ https://issues.apache.org/jira/browse/KARAF-5542?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Guillaume Nodet resolved KARAF-5542.
------------------------------------
    Resolution: Fixed

Doing multiple calls to installFeature is not wrong per se, the result will be the same at the end, but the path taken is different.  If you have a list of features to install, then yes, definitely use a single call, as the whole deployment will be recomputed each time to call the FeaturesService.

> Installing a feature triggers restarting previous ones
> ------------------------------------------------------
>
>                 Key: KARAF-5542
>                 URL: https://issues.apache.org/jira/browse/KARAF-5542
>             Project: Karaf
>          Issue Type: Bug
>          Components: karaf-feature
>    Affects Versions: 4.1.3
>         Environment: Windows, JRE8
>            Reporter: Lukasz Lech
>            Assignee: Jean-Baptiste Onofré
>            Priority: Minor
>             Fix For: 4.2.0, 4.1.5
>
>
> In my project, I've noticed, that installing a feature triggers restarting another features. I've noticed this behaviour seeing in console, that Liquibase database updater starts multiple times. 
> I was able to prepare feature set that replicates the behaviour in github:
> https://github.com/llech/karaf-refresh-demo/tree/master
> jersey-features is the wrapper for jax-rs publisher that I've found 'somewhere in internet' .
> module-features are the very simplified version of my project, nevertheless the bug triggers.
> install both features with maven, then in karaf console type:
> feature:repo-add mvn:org.apache.aries.jpa/jpa-features/2.7.0-SNAPSHOT/xml/features
> feature:repo-add mvn:com.eclipsesource.jaxrs/features/5.3/xml/features
> feature:repo-add mvn:com.example/jersey-features/2.2.2-SNAPSHOT/xml/features
> feature:repo-add mvn:com.example/module-features/1.0.0-SNAPSHOT/xml/features
> feature:install module-liquibase
> feature:install module-part1
> feature:install module-part2 
> You'll notice that each subsequent feature triggers reloading previous features.
> It looks like that in karaf.log:
> 2017-12-14T12:17:31,863 | INFO  | pipe-feature:install module-part2 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 | Adding features: module-part2/[1.0.0.SNAPSHOT,1.0.0.SNAPSHOT]
> 2017-12-14T12:17:33,057 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 | Changes to perform:
> 2017-12-14T12:17:33,057 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   Region: root
> 2017-12-14T12:17:33,057 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |     Bundles to uninstall:
> 2017-12-14T12:17:33,057 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |       javax.persistence/2.1.1.v201509150925
> 2017-12-14T12:17:33,058 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |     Bundles to install:
> 2017-12-14T12:17:33,058 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |       mvn:com.google.code.gson/gson/2.7
> 2017-12-14T12:17:33,058 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |       mvn:com.io7m.jcip/jcip-annotations/1.0.2
> 2017-12-14T12:17:33,058 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |       mvn:net.minidev/accessors-smart/1.1
> 2017-12-14T12:17:33,058 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |       mvn:net.minidev/json-smart/1.3.1
> 2017-12-14T12:17:33,058 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |       mvn:org.apache.commons/commons-dbcp2/2.1.1
> 2017-12-14T12:17:33,058 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |       mvn:org.apache.tika/tika-core/1.16
> 2017-12-14T12:17:33,059 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |       mvn:org.ops4j.pax.jdbc/pax-jdbc-config/1.1.0
> 2017-12-14T12:17:33,059 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |       mvn:org.ops4j.pax.jdbc/pax-jdbc-pool-common/1.1.0
> 2017-12-14T12:17:33,059 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |       mvn:org.ops4j.pax.jdbc/pax-jdbc-pool-dbcp2/1.1.0
> 2017-12-14T12:17:33,059 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |       mvn:org.postgresql/postgresql/9.4.1212.jre7
> 2017-12-14T12:17:33,059 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 | Stopping bundles:
> 2017-12-14T12:17:33,059 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   javax.persistence/2.1.1.v201509150925
> 2017-12-14T12:17:33,060 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 | Uninstalling bundles:
> 2017-12-14T12:17:33,060 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   javax.persistence/2.1.1.v201509150925
> 2017-12-14T12:17:33,069 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 | Installing bundles:
> 2017-12-14T12:17:33,069 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   mvn:com.google.code.gson/gson/2.7
> 2017-12-14T12:17:33,080 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   mvn:com.io7m.jcip/jcip-annotations/1.0.2
> 2017-12-14T12:17:33,119 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   mvn:net.minidev/accessors-smart/1.1
> 2017-12-14T12:17:33,130 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   mvn:net.minidev/json-smart/1.3.1
> 2017-12-14T12:17:33,141 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   mvn:org.apache.commons/commons-dbcp2/2.1.1
> 2017-12-14T12:17:33,152 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   mvn:org.apache.tika/tika-core/1.16
> 2017-12-14T12:17:33,165 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   mvn:org.ops4j.pax.jdbc/pax-jdbc-config/1.1.0
> 2017-12-14T12:17:33,239 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   mvn:org.ops4j.pax.jdbc/pax-jdbc-pool-common/1.1.0
> 2017-12-14T12:17:33,298 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   mvn:org.ops4j.pax.jdbc/pax-jdbc-pool-dbcp2/1.1.0
> 2017-12-14T12:17:33,353 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   mvn:org.postgresql/postgresql/9.4.1212.jre7
> 2017-12-14T12:17:33,400 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 | Stopping bundles:
> 2017-12-14T12:17:33,401 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   org.apache.aries.transaction.manager/1.3.3
> 2017-12-14T12:17:33,432 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   org.apache.aries.jpa.javax.persistence_2.1/2.7.0.SNAPSHOT
> 2017-12-14T12:17:33,433 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   org.apache.aries.jpa.eclipselink.adapter/2.6.1
> 2017-12-14T12:17:33,435 | INFO  | features-1-thread-1 | FeaturesServiceImpl              | 9 - org.apache.karaf.features.core - 4.1.2 |   com.eclipsesource.jaxrs.publisher/5.3.1.201602281253
> The suspicious line is about uninstalling javax.persistance. It is likely to cascade all other operations.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)