You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@karaf.apache.org by Richard Hierlmeier <rh...@googlemail.com> on 2021/04/22 12:29:48 UTC

Best practice for migrating a Karaf 3 feature to Karaf 4

What is the best practise for migrating a Kara 3 feature to Karaf 4.

The karaf-maven-plugin many new features. However I can not find good
example how to use it.
In the Karaf git repository the packaging "feature" is not used (only in
integration tests).
Is it deprecated?


Thank you in advance

  Richard

Re: Best practice for migrating a Karaf 3 feature to Karaf 4

Posted by Jean-Baptiste Onofre <jb...@nanthrax.net>.
Hi,

That’s true, but you can use "template", so it’s kind of mixed approach: the bundle version comes from the Maven dependency set, and the features structure is "manual".

Regards
JB

> Le 23 avr. 2021 à 08:46, Richard Hierlmeier <rh...@googlemail.com> a écrit :
> 
> 
> In Karaf 3 we defined configurations and features in the features.xml file (input file). The bundle came from the Maven dependendies.
> So we use a mixed approach.
> 
> I will try now to define everything in feature.xml.
> I see one disadvantage here. I cannot define the bundle versions directly in the Maven dependency management section. I have to define for each bundle version a Maven property.
> 
> 
> Richard
> 
> 
> Am Do., 22. Apr. 2021 um 16:29 Uhr schrieb Jean-Baptiste Onofre <jb@nanthrax.net <ma...@nanthrax.net>>:
> Hi Richard,
> 
> It depends if you want to generate features manually or with the help of the plugin.
> 
> Generally speaking, for complete control, we do the features XML (or json) by hand (especially to split cleanly features, use dependency or prerequisite flags).
> 
> Regards
> JB
> 
> > Le 22 avr. 2021 à 14:29, Richard Hierlmeier <rhierlmeier@googlemail.com <ma...@googlemail.com>> a écrit :
> > 
> > 
> > What is the best practise for migrating a Kara 3 feature to Karaf 4.
> > 
> > The karaf-maven-plugin many new features. However I can not find good example how to use it.
> > In the Karaf git repository the packaging "feature" is not used (only in integration tests).
> > Is it deprecated?
> > 
> > 
> > Thank you in advance
> > 
> >   Richard
> > 
> > 
> > 
> > 
> > 
> > 
> 


Re: Best practice for migrating a Karaf 3 feature to Karaf 4

Posted by Richard Hierlmeier <rh...@googlemail.com>.
In Karaf 3 we defined configurations and features in the features.xml file
(input file). The bundle came from the Maven dependendies.
So we use a mixed approach.

I will try now to define everything in feature.xml.
I see one disadvantage here. I cannot define the bundle versions directly
in the Maven dependency management section. I have to define for each
bundle version a Maven property.


Richard


Am Do., 22. Apr. 2021 um 16:29 Uhr schrieb Jean-Baptiste Onofre <
jb@nanthrax.net>:

> Hi Richard,
>
> It depends if you want to generate features manually or with the help of
> the plugin.
>
> Generally speaking, for complete control, we do the features XML (or json)
> by hand (especially to split cleanly features, use dependency or
> prerequisite flags).
>
> Regards
> JB
>
> > Le 22 avr. 2021 à 14:29, Richard Hierlmeier <rh...@googlemail.com>
> a écrit :
> >
> >
> > What is the best practise for migrating a Kara 3 feature to Karaf 4.
> >
> > The karaf-maven-plugin many new features. However I can not find good
> example how to use it.
> > In the Karaf git repository the packaging "feature" is not used (only in
> integration tests).
> > Is it deprecated?
> >
> >
> > Thank you in advance
> >
> >   Richard
> >
> >
> >
> >
> >
> >
>
>

Re: Best practice for migrating a Karaf 3 feature to Karaf 4

Posted by Jean-Baptiste Onofre <jb...@nanthrax.net>.
Hi Richard,

It depends if you want to generate features manually or with the help of the plugin.

Generally speaking, for complete control, we do the features XML (or json) by hand (especially to split cleanly features, use dependency or prerequisite flags).

Regards
JB

> Le 22 avr. 2021 à 14:29, Richard Hierlmeier <rh...@googlemail.com> a écrit :
> 
> 
> What is the best practise for migrating a Kara 3 feature to Karaf 4.
> 
> The karaf-maven-plugin many new features. However I can not find good example how to use it.
> In the Karaf git repository the packaging "feature" is not used (only in integration tests).
> Is it deprecated?
> 
> 
> Thank you in advance
> 
>   Richard
> 
> 
> 
> 
> 
>