Hi Charlie,

You can use wrap: with Import-Package statement directly in URL.

Like this, you can do this "on the fly", without changing the existing bundle, and without creating a new artifact.

More over, this kind of transformer already exist for the shade plugin.
It's what I use in ServiceMix bundle for elasticsearch for instance:

                            <transformers>
<transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer"/>
                            </transformers>

Here it's the ServicesResourceTransformer, but you can provide your own transformer.

Regards
JB

On 06/11/2014 11:02 PM, Charlie Mordant wrote:
Hi Karaf community,

If as me you want to increase the range of some package import versions
in a bundle you're depending, you can use my Manifest import version
updater:
https://github.com/OsgiliathEnterprise/net.osgiliath.parent/tree/master/net.osgiliath.framework/net.osgiliath.helpers.parent/net.osgiliath.helpers.manifest.transformer

Here's an example of usage in a pom (it'll convert a range for guava
packages from [13, 14) to [13,17]:
https://github.com/OsgiliathEnterprise/net.osgiliath.parent/blob/master/net.osgiliath.framework/net.osgiliath.helpers.parent/net.osgiliath.wrappers/net.osgiliath.wrapper.swagger-jaxrs/pom.xml

Feel free to use, integrate it in any plugin...

It will also be on Maven Central in one or two weeks.

Best regards,

--
Charlie Mordant

Full OSGI/EE stack made with Karaf:
https://github.com/OsgiliathEnterprise/net.osgiliath.parent

--
Jean-Baptiste Onofré
[email protected]
http://blog.nanthrax.net
Talend - http://www.talend.com

Reply via email to