Bus statistics - org.freedesktop.DBus.Debug.Stats
simon.mcvittie at collabora.co.uk
Tue Jun 23 02:51:54 PDT 2015
On 23/06/15 07:12, Umut Tezduyar Lindskog wrote:
> I have found the promising interface
> "org.freedesktop.DBus.Debug.Stats" but the interface is not mentioned
> in dbus spec.
I consider this interface to be an implementation detail of the
reference dbus-daemon. You can use it to gather statistics from
dbus-daemon, if you know you have a new enough version compiled with
--enable-stats. However, you cannot rely on third-party
reimplementations (or old or minimal installations of dbus-daemon)
having this interface.
If you want to add extra properties or methods to that interface, please
send patches to the usual place (freedesktop.org Bugzilla). I'm happy to
add anything that has a low runtime cost (in terms of CPU, memory and
lines-of-code) - counting bytes would be fine, for instance. Anything
"expensive" should be a separate --enable option.
> Is this interface meant to be officially supported so we
> can have it in kdbus too?
Interfaces on o.fd.DBus are unlikely to ever be implemented in kdbus,
because the closest equivalent of dbus-daemon in kdbus is a kernel
module. The way to get analogous statistics and debug information out of
kdbus would be a special ioctl or a file in /sys.
> Can someone explain it a bit more, or point to a document that explains it?
At the moment, the source code is the documentation. If you are not
comfortable with finding things in the dbus source code, this interface
is probably not for you (but I'd be willing to review a patch to add
documentation to a text or Docbook file in the doc directory).
I do not think this interface should be documented in the D-Bus
Specification. It is not part of the interoperable subset of D-Bus; I
don't expect systemd-bus-proxy, gdbus-daemon or dbus-sharp's managed
dbus-daemon to ever implement it, for instance.
Collabora Ltd. <http://www.collabora.com/>
More information about the dbus