Hi all, Appreciate any response on the above questions.
Thanks, Nipuni On Thu, Mar 24, 2016 at 8:05 PM, Nipuni Piyabasi Perera < nipuni880...@gmail.com> wrote: > Hi all, > > I am trying to implement OSGI URL scheme support for JNDI following the > OSGI service specification[1]. While implementing the OSGI URL scheme I > encountered following issues. > As per the specification, Following are the confusions I have: > > 1. A lookup with osgi:service path will return a service while a > servicelist path returns an context object. Does a query > "osgi:servicelist/" is valid? Or is it mandatory to have a query followed > by the osgi:servicelist/ ? > 2. As per the specification, listBindings() and list() methods will > return NamingEnumeration objects. Do both "service" and "servicelist" paths > need to support aforementioned methods? > 1. context.list("osgi:service/<qname>") is this a valid URL ? > 2. context.list(osgi:servicelist/<qname>) is this a valid URL ? > 1. If this is a valid scenario, does the Context object need to > obtain first before doing list() and listbinding() queries? (Please > find a > sample code below) > 2. > > Context context = jndiContextManager.newInitialContext(); > > Context listContext = > context.lookup("osgi:servicelist/org.my.jndi.osgi.services.FooService") > > NamingEnumeration<NameClassPair> namingEnumeration = > > > listContext.list("osgi:service/org.wso2.carbon.jndi.osgi.services.FooService"); > > 3. > > In a scenario as above, is it valid to pass two different names to > list() and lookup() methods (i.e context.lookup("osgi:servicelist/SERVICE-A") > and do a context.list(osgi:servicelist/SERVICE-B)) ? > > 3. As per the specification we mainly support list(), > listbindings(), and lookup() methods. Can we consider the other methods > such as bind(), rebind() , unbind() , rename() as operations that are not > supported with the provider? > > Appreciate any input on above queries. > > [1] https://osgi.org/download/r6/osgi.enterprise-6.0.0.pdf > <https://www.osgi.org/developer/downloads/release-6/release-6-download/> > > Thanks, > Nipuni > > -- > Nipuni Perera > Software Engineer; WSO2 Inc.; http://wso2.com > Email: nip...@wso2.com > Git hub profile: https://github.com/nipuni > Blog : http://nipunipererablog.blogspot.com/ > Mobile: +94 (71) 5626680 > -- Nipuni Perera Software Engineer; WSO2 Inc.; http://wso2.com Email: nip...@wso2.com Git hub profile: https://github.com/nipuni Blog : http://nipunipererablog.blogspot.com/ Mobile: +94 (71) 5626680
_______________________________________________ OSGi Developer Mail List osgi-dev@mail.osgi.org https://mail.osgi.org/mailman/listinfo/osgi-dev