Hi,

Instead of importing packages, you can embed the packages in your bundle.

You have three ways to achieve this using the maven-bundle-plugin:

1. Using Bundle-Classpath instruction
2. Using Embed-Dependency instruction
3. Using Private-Package instruction

Regards
JB

On 09/09/2018 21:35, Steinar Bang wrote:
>>>>>> Jean-Baptiste Onofré <j...@nanthrax.net>:
> 
>> why you don't just put this as private package. You will avoid class
>> loading issue this way.
> 
>> In OSGi, not all is necessary an import. It could be a private package
>> and/or embed dependency. It means the packages are embedded in the
>> bundle. The bundle is "fat" but you avoid classloading issue this way,
>> especially when the dependency is not designed for OSGi.
> 
> Um... not sure what you mean...?  Do you mean rebundling Neo4J before
> pulling it into karaf?  Either individually (*lots* of work, probably),
> or as a fat jar (less work if the maven dependencies of the top jar can
> be made to do the trick).
> 
>> Unfortunately, I wanted to create neo4j bundle at ServiceMix, but it's
>> not possible due to neo4j license.
> 
> Yeah, the licensing was why I didn't rebundle with maven in the first
> place.  I hoped the wrap protocol could do the trick...
> 

-- 
Jean-Baptiste Onofré
jbono...@apache.org
http://blog.nanthrax.net
Talend - http://www.talend.com

Reply via email to