You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@karaf.apache.org by "Karen (JIRA)" <ji...@apache.org> on 2018/05/21 12:53:00 UTC

[jira] [Comment Edited] (KARAF-4996) Missing packages in created instances

    [ https://issues.apache.org/jira/browse/KARAF-4996?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16482468#comment-16482468 ] 

Karen edited comment on KARAF-4996 at 5/21/18 12:52 PM:
--------------------------------------------------------

[~jbonofre] I believe this is related: In ticket KARAF-5693, we get error  "exposed to package 'javax.annotation' from resources javax.annotation-api [javax.annotation-api [27](R 27.0)] and org.apache.
 felix.framework [org.apache.felix.framework [0](R 0)] via two dependency chains" when javax.annotation is missing from property {{org.osgi.framework.system.packages.extra}} in file {{etc\config.properties}} but does exist in the lib/endorsed.

For example, our assemblies/pom.xml has <library>mvn:javax.annotation/javax.annotation-api/1.2;type:=endorsed;export:=true</library>. The javax.annotation-api-1.2.jar is added to lib/endorsed, but the "javax.annotation;version=1.2" occasionally gets omitted/removed from config.properties during karaf-maven-plugin.

No BootFeaturesInstaller constraint violation violation (annotation jar in lib/endorsed and "javax.annotation;version=1.2"  is also in {{org.osgi.framework.system.packages.extra}})
 karaf@root> package:exports
 javax.annotation                                      | 1.2.0            | 0   | org.apache.felix.framework
 javax.annotation                                      | 1.2.0            | 27  | javax.annotation-api

BootFeaturesInstaller constraint violation from 2 dependency chains (annotation jar in lib/endorsed but not in {{org.osgi.framework.system.packages.extra}})
 karaf@root> package:exports
 javax.annotation                                      | 1.2.0            | 27  | javax.annotation-api
 javax.annotation                                      | 1.2.0            | 0   | org.apache.felix.framework


was (Author: kdolan):
[~jbonofre] I believe this is related: In ticket KARAF-5693, we get error  "exposed to package 'javax.annotation' from resources javax.annotation-api [javax.annotation-api [27](R 27.0)] and org.apache.
felix.framework [org.apache.felix.framework [0](R 0)] via two dependency chains" when javax.annotation is missing from property {{org.osgi.framework.system.packages.extra}} in file {{etc\config.properties}} but does exist in the lib/endorsed. 

For example, our assemblies/pom.xml has <library>mvn:javax.annotation/javax.annotation-api/1.2;type:=endorsed;export:=true</library>. The javax.annotation-api-1.2.jar is added to lib/endorsed, but the "javax.annotation;version=1.2" occasionally gets omitted/removed from config.properties during karaf-maven-plugin.

No BootFeaturesInstaller constraint violation violation (annotation jar in lib/endorsed and also in {{org.osgi.framework.system.packages.extra}})
karaf@root> package:exports
javax.annotation                                      | 1.2.0            | 0   | org.apache.felix.framework
javax.annotation                                      | 1.2.0            | 27  | javax.annotation-api

BootFeaturesInstaller constraint violation from 2 dependency chains (annotation jar in lib/endorsed but not in {{org.osgi.framework.system.packages.extra}})
karaf@root> package:exports
javax.annotation                                      | 1.2.0            | 27  | javax.annotation-api
javax.annotation                                      | 1.2.0            | 0   | org.apache.felix.framework

> Missing packages in created instances 
> --------------------------------------
>
>                 Key: KARAF-4996
>                 URL: https://issues.apache.org/jira/browse/KARAF-4996
>             Project: Karaf
>          Issue Type: Bug
>          Components: karaf-core
>    Affects Versions: 4.0.8, 4.1.5
>         Environment: java version "1.8.0_121"
> Java(TM) SE Runtime Environment (build 1.8.0_121-b13)
> Java HotSpot(TM) 64-Bit Server VM (build 25.121-b13, mixed mode)
> Linux 4.4.0-63-generic Ubuntu
>            Reporter: Rocco Lagrotteria
>            Assignee: Jean-Baptiste Onofré
>            Priority: Major
>             Fix For: 4.0.11, 4.1.6
>
>
> Many packages exported by System Bundle (ID 0) are missing in instances different than root instance.
> To reproduce:
> {noformat}
> karaf@root()> package:exports -b 0 -p org.apache.xpath
> Package Name                | Version | ID | Bundle Name
> -----------------------------------------------------------------------
> org.apache.xpath.axes       | 2.7.2   | 0  | org.apache.felix.framework
> org.apache.xpath.compiler   | 2.7.2   | 0  | org.apache.felix.framework
> org.apache.xpath.domapi     | 2.7.2   | 0  | org.apache.felix.framework
> org.apache.xpath.functions  | 2.7.2   | 0  | org.apache.felix.framework
> org.apache.xpath.jaxp       | 2.7.2   | 0  | org.apache.felix.framework
> org.apache.xpath.objects    | 2.7.2   | 0  | org.apache.felix.framework
> org.apache.xpath.operations | 2.7.2   | 0  | org.apache.felix.framework
> org.apache.xpath.patterns   | 2.7.2   | 0  | org.apache.felix.framework
> org.apache.xpath.res        | 2.7.2   | 0  | org.apache.felix.framework
> org.apache.xpath            | 2.7.2   | 0  | org.apache.felix.framework
> karaf@root()> instance:create test
> karaf@root()> instance:start test
> karaf@root()> instance:connect test
> karaf@test()> package:exports -b 0 -p org.apache.xpath
> Package Name | Version | ID | Bundle Name
> -----------------------------------------
> karaf@test()>
> {noformat}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)