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

Frank Diebolt commented on KARAF-3475:
--------------------------------------

Hi,

Sorry, I neither saw JIRA -3371 neither any commit fixing this issue in the 
3.0.x branch...

I encountered the issue after deploying the webconsole feature (that must 
deploy the pax-web-runtime bundle I guess) then later the war feature which 
adds the pax-web-jsp bundle.
Since pax-web-jsp is deployed after pax-web-runtime, the JSP support isn't 
working.

Indeed, JSP is an optional import of the runtime and must be available before 
the runtime is resolved or the runtime must be refreshed. The karaf feature 
installer seems to deal with it, since I can see a list of bundles to refresh 
identified to have optional imports that have been updated at the end of the 
feature install...

Miserably, the karaf feature announces a bundle refresh but actually does 
nothing since only the 0 system bundle exports the FrameworkWiring service.

It's strange that this fix has such a side effect on IT tests :-(
Sorry, I won't be able to make additional tests before 3 weeks.

But it would be great to have this fix (same as JIRA-3371) in the 3.0.3 version.

BR
Frank

> No refresh of bundles during feature install
> --------------------------------------------
>
>                 Key: KARAF-3475
>                 URL: https://issues.apache.org/jira/browse/KARAF-3475
>             Project: Karaf
>          Issue Type: Bug
>          Components: karaf-feature
>    Affects Versions: 3.0.2
>            Reporter: Frank Diebolt
>            Assignee: Jean-Baptiste Onofré
>             Fix For: 4.0.0, 3.0.4
>
>   Original Estimate: 5m
>  Remaining Estimate: 5m
>
> Hi,
> I successfully tested the fix below :
> In the source file 
> <karaf-sources>features/core/src/main/java/org/apache/karaf/features/internal/BundleManager.java
> protected void refreshPackages(Collection<Bundle> bundles) {
>         final Object refreshLock = new Object();
> -FrameworkWiring wiring = 
> bundleContext.getBundle().adapt(FrameworkWiring.class);
> +FrameworkWiring wiring = 
> bundleContext.getBundle(0).adapt(FrameworkWiring.class);
> Currently wiring is always null, FrameworkWiring can be obtained on bundle 0 
> only.
> BR
> Frank



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to