Thank you both. It turns out my bundle was not importing the package of the
super-interface. Manually adding it to the Import-Package in the manifest
resolved the issue. Is this a bug in the maven-bundle-plugin? I did a quick
search on Jira, but I saw no mention of this problem. I don't mind filing
an issue, but is this working as intended? Am I missing something?

Thanks again.

On Sat, Oct 20, 2012 at 1:40 AM, Clement Escoffier <
[email protected]> wrote:

> Hi,
>
> The error means that iPOJO can't load the interface. IT's required to be
> sure that the POJO is able to server the service.
> Your bundle containing your components must import the package of the
> interfaces as well as the packages of the parent interfaces. I suspect that
> the 2 interfaces are in 2 different packages.
>
> So, if you have this:
> The bundle A contains and exports my.package.interfaces (containing
> ISampleService) and my.package.interfaces.parent containing (ICoreService)
> The bundle B with my.package.impl.MyComponent.class must import
> my.package.interfaces AND my.package.interfaces.parent
>
> Could you, as Göktürk suggested, send us your manifest of the 2 bundles.
>
> Regards,
>
> Clement
>
>
> On 20 oct. 2012, at 01:36, lessonz <[email protected]> wrote:
>
> > Okay, so I realized I'd been ignoring an error. There is an error I'd be
> > unintentionally ignoring:
> >
> >        [Thread-1] ERROR com.sample.bundle - [ERROR]
> > com.sample.SampleServiceImpl : Service Providing: The service
> specification
> > com.sample.ICoreService cannot be load
> >
> > Okay, this happened when I had ISampleService extend ICoreService. Some
> > other details. SampleServiceImpl  is in one bundle. Both ISampleService
> and
> > ICoreService are in one, but a different, bundle. They are in different
> > packages, but the bundle exports both of these packages. The ICoreService
> > interface has 0 imports. I see the error even if I have SampleServiceImpl
> > import ICoreService directly. If I make ISampleService NOT extend
> > ICoreService, the error goes away (makes sense) and SampleServiceImpl
> gets
> > instantiated no problem.
> >
> > Any ideas would be greatly appreciated.
> >
> > Thanks
> > On Oct 18, 2012 7:14 PM, "lessonz" <[email protected]> wrote:
> >
> >> I’m using IPOJO.
> >>
> >>
> >> Okay, I’ve got one that has me stumped. I have a component with some
> >> member components:
> >>
> >>
> >> @Component
> >>
> >> @Instantiate
> >>
> >> @Provides
> >>
> >> public class SampleServiceImpl implements ISampleService {
> >>
> >>                @Requires
> >>
> >>                private ITestAService testAService;
> >>
> >>                @Requires
> >>
> >>                private ITestBService testBService;
> >>
> >> .
> >>
> >> .
> >>
> >> .
> >>
> >> }
> >>
> >>
> >> If I have the interface ITestAService extend ICoreService everything
> seems
> >> to work just fine, but if I have ITestBService extend ICoreService then
> >> ITestBService and SampleServiceImpl never register. This really doesn’t
> >> make any sense to me. There doesn’t appear to be any rhyme or reason to
> it.
> >> As I don't understand how this is possible, it's entirely possible I'm
> >> missing something that is material to the conversation. I'm just not
> sure
> >> what it is. I'd love any ideas about where to look.
> >>
> >>
> >> Our architecture would ideally have ISampleService, ITestAService, and
> >> ITestBService all have ICoreService as a super-interface. The
> documentation
> >> seems to indicate this should be possible, but for some reason I can’t
> get
> >> it to work. Am I missing something?
> >>
> >>
> >> Thanks
> >>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>

Reply via email to