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

David Bosschaert commented on SLING-8484:
-----------------------------------------

 {quote}
but what situations does the analyzer and the system ready check not catch?
{quote}

I can think of some situations that the analyzer doesn't catch:

1. Bundle.start() throws an exception. I don't think the analyzers can catch 
that. Granted, this only works for bundles that are not lazy activation, but my 
gut feeling says that most bundles don't have {{Bundle-ActivationPolicy: 
lazy}}. 
 2. There could be a case where maybe the analyzers got it wrong, as they are 
not _the_ framework. I can think of a situation where a framework creates a 
number of class-spaces and the analyzers didn't take this into account during 
the analyze phase.
 3. If you just launch a combination of features that were not analyzed 
together, and something goes wrong there. Granted, with [~dsuess]'s 
[extension|https://github.com/DominikSuess/sling-whiteboard/tree/master/feature-analyser-extension],
 you can run the analyzer as part of the launcher, but I'm not sure if 
everybody wants to do this, as it will take considerable extra time for the 
launcher.

Regarding the system ready check:
 1. This is a timeout based system, so it will take (much) longer before it 
fails. It's much higher level than simply checking that all the bundles were 
able to start. Because it's configurable it may not even be checking that in 
the first place.
 2. System ready is a separate independent component. Not everybody may have 
this in their system.

On the start levels. Yes, I think for this we have to assume that the beginning 
start level is set. If this is changed later to a desired start level there is 
not much we can do at this level.

So I'm not saying that it covers all the cases, but this is quite a cheap 
mechanism which in my opinion could help. In my test scenario it works, 
although I have to admit that my test scenario only has about 15 bundles right 
now.

> Fail the launcher if not all bundles could be launched
> ------------------------------------------------------
>
>                 Key: SLING-8484
>                 URL: https://issues.apache.org/jira/browse/SLING-8484
>             Project: Sling
>          Issue Type: Improvement
>    Affects Versions: Feature Model Launcher 1.0.2
>            Reporter: David Bosschaert
>            Assignee: David Bosschaert
>            Priority: Major
>             Fix For: Feature Model Launcher 1.0.4
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> If the launcher is not able to start all bundles successfully, the launcher 
> should fail with a non-zero exit code.
> This functionality should not be the default. It needs to be enabled with a 
> flag, for example -foe (Fail on Error)



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

Reply via email to