Guillaume Nodet commented on FELIX-5383:

What do you mean by causes a service timeout ?
Unless you use non default, which would imply you know exactly what you're 
doing, service references in blueprint will cause the whole application start 
to be delayed until the dependency is resolved, so you can only get a service 
timeout exception if a bundle providing a service is *stopped*, and then a call 
to this service dependency.  
The other possibility is that you have an optional dependency.  If that's 
actually your use case, you can set the 
{{org.apache.aries.blueprint.synchronous}} property to {{false}} and your 
bundles will all be started asynchronously.  That's the default value for 
blueprint, but karaf changes the default to {{true}}.

> Support parallel bundle starting
> --------------------------------
>                 Key: FELIX-5383
>                 URL: https://issues.apache.org/jira/browse/FELIX-5383
>             Project: Felix
>          Issue Type: Improvement
>          Components: File Install
>    Affects Versions: fileinstall-3.5.4
>            Reporter: Matt Magoffin
> I have an application that uses Felix File Install to start a set of bundles 
> that use Blueprint configuration extensively, but with the poll time disabled 
> ({{felix.fileinstall.poll = 0}}) because I only want the bundles started at 
> application startup time. Sometimes one bundle might have a Blueprint service 
> dependency provided by another bundle such that when started and that other 
> bundle has not been started yet causes a service timeout. The ordering File 
> Install uses to start bundles is indeterminate (a {{HashSet}} is passed to 
> {{startBundles(Collection<Bundle> bundles)}}) so I thought a good solution 
> would be to start bundles in parallel, so if one bundle gets stuck when 
> starting, waiting for a Blueprint service to become available, other bundles 
> can continue to be started under the assumption one of them will be providing 
> that service "soon".

This message was sent by Atlassian JIRA

Reply via email to