aries-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jarek Gawor <>
Subject jndi integration question
Date Tue, 06 Oct 2009 18:48:24 GMT

I have a question about the jndi integration code. The
ServiceRegistryContext.lookup("osgi:services/foo") returns a service
instance registered with interface foo. But
ServiceRegistryContext.list("osgi:services/foo") (or listBindings())
returns a list of services registered with that interface. That's a
bit odd to me since I thought if you can do list() or listBindings()
on a name, the lookup() on the same name should return
javax.naming.Context object. That is, for example, ((Context)
context.lookup("bar")).listBindings("") should return pretty much the
same info as doing context.listBindings("bar").
I know the lookup() behavior is mandated by the spec but what about
the list()/listBindings()? Seems to me like the ServiceRegistryContext
should not implement the list()/listBindings() methods.


View raw message