Hi David, Thank you again for the explanation. If I understand correctly when comes to InitialContextFactory, SPY-Fly registering mechanism will not adhere to OSGi JNDI spec, since it needs to registered for both implementation and interface. Therefore I guess I have to do some customization to SPY-Fly if the interface is an InitialContextFactory. Am I correct?
Thanks Thusitha <https://mailtrack.io/> Sent with Mailtrack <https://mailtrack.io/install?source=signature&lang=en&[email protected]&idSignature=22> On Tue, Oct 3, 2017 at 10:18 PM, David Bosschaert < [email protected]> wrote: > Hi Thusitha, > > I'm starting to understand your use case a little better now - it's been a > while since I looked at JNDI, but I *think* the following could work... > > * Use SPI-Fly to register the InitialContext/InitialContextFactory in the > service registry from the /META-INF/services info. > * Use Aries JNDI to use that service and connect it with OSGi JNDI support. > > There might be some details to work out, but that might get you what > you're looking for. > > Best regards, > > David > > On 3 October 2017 at 18:17, Thusitha Thilina Dayaratne < > [email protected]> wrote: > >> Hi David, >> >> Thank you very much for the explanation and for the information. Just to >> be clear, does Aries JNDI provide support to register SPIs in OSGi >> environment similar to SPY-Fly? Or do I need to manually register the >> providers(InitialContextFactory) according to the OSGi spec? >> >> Regards >> Thusitha >> >> <https://mailtrack.io/> Sent with Mailtrack >> <https://mailtrack.io/install?source=signature&lang=en&[email protected]&idSignature=22> >> >> On Tue, Oct 3, 2017 at 9:39 PM, David Bosschaert < >> [email protected]> wrote: >> >>> Hi, >>> >>> I guess you're looking for an implementation of the OSGi JNDI Services >>> specification (OSGi Enterprise spec [1] chapter 126) since that's the one >>> that deals with the InitialContextFactory. >>> SPI-Fly is an implementation of a different spec, namely the OSGi >>> ServiceLoader Mediator Specification (chapter 133), so I guess it won't >>> help you here. >>> >>> There is an implementation of the OSGi JNDI spec in Aries as well, >>> documentation can be found at [2] and source code at [3]. >>> >>> Hope this helps, >>> >>> David >>> >>> [1] https://www.osgi.org/developer/downloads/release-6/ >>> [2] http://aries.apache.org/modules/jndiproject.html >>> [3] https://svn.apache.org/repos/asf/aries/trunk/jndi >>> >>> On 3 October 2017 at 14:31, Thusitha Thilina Dayaratne < >>> [email protected]> wrote: >>> >>>> Hi All, >>>> >>>> I'm trying to use Aries SPYFly with one of our projects. According to >>>> the OSGi spec when we register an InitialContextFactory, we need to >>>> register that for both implementation and InitialContextFactory classes. >>>> But as I experienced SPIFly only doesn't register that for particular >>>> implementation (only for the InitialContextFactory) >>>> >>>> Did I missed anything or is this an issue? >>>> >>>> Thanks >>>> Thusitha >>>> -- >>>> >>>> >>> >>> >> >> >> -- >> >> > > --
