New program for tools: dbus-service.c
Havoc Pennington
hp@redhat.com
21 Sep 2003 14:21:39 -0400
On Sun, 2003-09-21 at 10:50, amk@amk.ca wrote:
> (I sent this a week ago, but the message never showed up; perhaps it's sitting
> in a moderator queue somewhere.)
Quite possible. ;-) The queue is packed with spam, and so sometimes I
miss the real messages in there.
> dbus-service, the program below, lets you specify up to 100 service names on
> the command line and will then listen to them, printing out any received
> messages. The printout is in enough detail that you could write a script
> that parsed dbus-service's output, making it possible to write services in
> languages without a dbus binding. (I'm evaluating D-BUS for use in a
> commercial application, and currently don't have time to get Python bindings
> working.)
This seems pretty useful. Ian Geiser has a very similar thing for DCOP;
one high-level comment would be that we might want to consider syncing
dbus-send and dbus-service up with the DCOP tools, since a primary goal
of D-BUS is to be easy to drop in for DCOP at some point.
We don't need to block committing dbus-service to CVS on this probably,
but in the future we may want to revamp these tools to match the DCOP
stuff, so the usual "ABI not frozen yet" caveat applies.
Speaking of that, soon I will be landing the dbus-object-names branch on
HEAD, which changes the API a fair bit; that will break this tool.
See the previous list mail "nove hrady discussion" for some of the ways
that branch changes things.
> Let me know if I need to sign a copyright assignment for the code to be
> added to the distribution. Comments on the use of the D-BUS API would also
> be helpful; is there anything I'm doing wrong?
I believe there are some convenience functions you could use, especially
on the dbus-object-names branch, but even on HEAD there's an acquire
service routine in dbus/dbus-bus.h IIRC. On the branch the DBusGProxy
may be useful.
We don't have copyright assignment at the moment.
Havoc