Hi Paul,

On 12 July 2017 at 13:12, Paul F Fraser <pa...@a2zliving.com> wrote:

> Hi David,
>
> I had a quick look at the examples but did not get far as some/most of the
> examples are poms and I did not proceed. I will have another look.
>
> Just a couple of questions,
>
> In my case I wrapped the acme4j jars in a bundle and manually added a
> META_INF.services folder then followed a suggestion of Peter's
> sometime ago to add
> Private-Package:  META-INF.services.*; -split-package:=merge-first
> This seems to do what is necessary in the generated mapped bundle.
> Is this the way to go?
>
> Also
> When using a wrapped bundle does the wrapped bundle and the application
> using it BOTH have to have the added Provide and/or Require Capabilities as
> per your blog or just the wrapped bundle.
> I could not follow this from the blog, not your fault, probably mine :-)
>

Since examples might be the best to get you going, here are some that come
close to what you're doing (I hope).
The spi-fly-example-provider2-bundle [1] shows the Provide-Capability
header that the provider should have and the spi-fly-example-client2-bundle
[2] should the Require-Capability that a consumer should have. There is
also an example that has an embedded jar file [3] but that uses the
'proprietary' Aries headers. However you can just use the same headers as
are used with [1] in that case.
However, these are just examples, the authorative info can be found in
chapter 133 of the Enterprise Spec [4].

Best regards,

David

PS. I don't think I every had to do a Private-Package instruction like you
have, but this may depend on the tooling settings and it shouldn't do any
harm.

[1]
https://svn.apache.org/repos/asf/aries/trunk/spi-fly/spi-fly-examples/spi-fly-example-provider2-bundle

[2]
https://svn.apache.org/repos/asf/aries/trunk/spi-fly/spi-fly-examples/spi-fly-example-client2-bundle
[3]
https://svn.apache.org/repos/asf/aries/trunk/spi-fly/spi-fly-examples/spi-fly-example-provider1-bundle
[4] https://osgi.org/members/Specifications/HomePage
_______________________________________________
OSGi Developer Mail List
osgi-dev@mail.osgi.org
https://mail.osgi.org/mailman/listinfo/osgi-dev

Reply via email to