Have you tried the following ?

    <feature name="feature-b" version="${project.version}"
description="Feature B">
        <bundle start-level="50">mvn:com.example/
bundle-a/${project.version}</bundle>
        <bundle start-level="60">mvn:com.example/
bundle-b/${project.version}</bundle>
    </feature>

2016-08-26 20:00 GMT+02:00 oski_bear <[email protected]>:

> I was able to solve my bundle ordering issues by creating feature
> dependencies. E.g.
>
>     <feature name="feature-a" version="${project.version}"
> description="Feature A">
>         <bundle>mvn:com.example/bundle-a/${project.version}</bundle>
>     </feature>
>
>     <feature name="feature-b" version="${project.version}"
> description="Feature B">
>         <feature prerequisite="true">feature-a</feature>
>         <bundle>mvn:com.example/bundle-b/${project.version}</bundle>
>     </feature>
>
> I have some mixed feelings about this solution. On the one hand, it's nice
> that it explicitly defines the dependency between the two bundles. On the
> other hand, it means I have to write way more XML, which should turn just
> about anybody off. It would be great if there was at least a way to respect
> ordering within a feature itself. Perhaps it could be an optional
> feature-by-feature setting.
>
> Finally, it seems like this is a breaking feature with respect to 2.x
> versions of Karaf. It would be nice to at least know the rationale for
> these
> changes. I can only theorize that the changes were put in place with the
> assumption that proper OSGi bundles should be able to start in any order.
> However, there are always exceptions to this and it would be great to have
> a
> consistent way to deal with those.
>
>
>
> --
> View this message in context: http://karaf.922171.n3.nabble.
> com/Karaf-4-0-5-bundle-startup-order-tp4047689p4047716.html
> Sent from the Karaf - User mailing list archive at Nabble.com.
>



-- 
------------------------
Guillaume Nodet
------------------------
Red Hat, Open Source Integration

Email: [email protected]
Web: http://fusesource.com
Blog: http://gnodet.blogspot.com/

Reply via email to