Extending Dbus Transport to allow use of mqueue

Havoc Pennington havoc.pennington at gmail.com
Mon Jan 19 22:32:35 PST 2009


Hi,

I think first you have to work out some conceptual questions, most
notably, how will your message queue integrate into a main loop? How
is all this intended to work with an app?

You'll need to understand how dbus main loop integration runs, see for example
http://cgit.freedesktop.org/dbus/dbus-glib/tree/dbus/dbus-gmain.c
http://cep.xor.aps.anl.gov/software/qt4-x11-4.2.2-browser/df/dcc/qdbusintegrator_8cpp-source.html

If we have some conceptual idea how this would work then the next step
is to figure out how to implement.

I'm guessing some additional public DBusConnection API would have to
exist and be used by main loop integration code such as the above
examples, to hook up message-queue-based transports.

The implementation would roughly involve a different DBusTransport but
since this would be the first non-file-descriptor based transport,
probably there will be some needed refactoring of internal APIs and
potentially additions to public APIs.

I would recommend profiling before you spend too much time on it;
libdbus has enough overhead that I'm not sure context switching is
your biggest problem.

Havoc


More information about the dbus mailing list