Hi,
thanks for the explanation.
Sorry if my explanation was not clear in my case the jar are shipped.
I added a dependency to the pom.
The dependency is taken into account (content added in the bundle and
manifest updated with import/export).
But my added jar contains itself jars.
And when deploying the bundle classes from the "included jars" are not seen
[missing import].
I used the maven shade-plugin manually to solve the problem :
i used : <Import-Package>myInternalPackage</Import-Package>
<Embed-Dependency>myInternalJar</Embed-Dependency>
It seems for me a bit ugly. I think there is a more elegant way to manage
"internal jars". I think some dependencies can be hidden in this case.
Some of the "included jars" are not present in maven repositories and it
becomes complicated to give to users a "customised" maven repository for a
dependency (if it was the solution by adding the dependency).
Thanks for answers
Regards
Hervé
On Wed, May 9, 2012 at 3:14 PM, Jean-Baptiste Onofré <[email protected]>wrote:
> Hi Hervé,
>
> You can add:
> - the jar in pom dependencies
> - update the shade include and filter artifact
>
> Like this the jars will be shipped in the ehcache generated bundle.
>
> Regards
> JB
>
>
> On 05/09/2012 02:37 PM, Hervé BARRAULT wrote:
>
>> Hi,
>>
>> Servicemix provides a package for ehcache.
>>
>> Here is the maven dependency.
>>
>> <groupId>org.apache.**servicemix.bundles</groupId>
>> <artifactId>org.apache.**servicemix.bundles.ehcache</**artifactId>
>> <version>2.5.1_1</version>
>>
>> In my case, i would use ehcache with a terracotta back-end.
>> In this case this package is not enough and i should add the dependencies
>> for terracotta-toolkit.
>>
>>
>> But in this case the jars which i want to transform as a bundle contain
>> jars.
>>
>> How can i handle these included jars ?
>>
>> I have seen the embed dependencies tag, but I have some difficulties to
>> use
>> them [it seems not for my case].
>>
>> terracotta-toolkit-1.4-**runtime-4.1.0.jar
>> +-L1/terracotta-l1-3.6.1.jar
>> +-L1/tim-api-1.3.0.jar
>> ...
>>
>> With this jar, all the content is well embedded (even L1 directory with
>> jars). But dependencies are not resolved correctly [it does not see
>> classes
>> inside included jars].
>> In order to ease the wrapping, I use as a parent pom :
>> <groupId>org.apache.**servicemix.bundles</groupId>
>> <artifactId>bundles-pom</**artifactId>
>> <version>8</version>
>>
>>
>> Thanks for answers
>> Regards
>> Hervé
>>
>>
> --
> Jean-Baptiste Onofré
> [email protected]
> http://blog.nanthrax.net
> Talend - http://www.talend.com
>