Getting a list of object paths for a service ?

Havoc Pennington hp at
Sun Sep 4 13:28:34 PDT 2005

On Sat, 2005-09-03 at 15:18 +0100, Daniel P. Berrange wrote:
> The recursive node hierarchy allowed for by Introspect() is something 
> that has been troubling me a little. For efficiency I suspect most 
> bindings will cache the XML from the Introspect() call the first time 
> its invoked on an object, because for any single object its basically
> static data. The trouble is, objects may conceivably pop in & out of 
> existance at any time. By allowing the Introspect XML to contain
> child nodes, one is effectively mixing dynamic data (the tree of objects),
> with static data (the API information), which ends up complicating
> caching of the data. For objects exported with the Perl bindings, I
> don't currently provide for adding data about child nodes in the 
> introspection XML of an object, since unless there are a huge number 
> of objects in use there's not going be a significant performance problem 
> calling Introspect() once on each individual object accessed.

That does make sense. So we could add a GetChildren() call basically
(maybe with a flags argument, with one flag being RECURSIVE and asking
to pull the whole tree at a given root)

Colin asked about getting roots, I think the roots would normally be
well-known (if you're talking about real application usage), but for
dbus-viewer or equivalent we might want a generic "get all roots" call
also. Maybe that's another flag to GetChildren(), ROOTS would
conceptually find all toplevel roots below a given path but then not
recurse into said roots.

I don't know, sounds like someone needs to think this through fully and
create a refined proposal (ideally in the form of a spec patch!)

We could probably put this stuff on the Introspectable interface, no?


More information about the dbus mailing list