[PATCH 0/5] Support service activation through Upstart

Lennart Poettering mzqohf at 0pointer.de
Thu Dec 23 07:28:50 PST 2010

On Thu, 23.12.10 14:54, Scott James Remnant (scott at netsplit.com) wrote:

> On Thu, Dec 23, 2010 at 12:35 PM, Thiago Macieira <thiago at kde.org> wrote:
> > On Thursday, 23 de December de 2010 12:28:41 Lennart Poettering wrote:
> >> Now after all that you do want this kind of activation hookup for
> >> upstart too, and now want to litter the D-Bus source code with multiple
> >> implementations which happen to be almost entirely identical except that
> >> a few strings are named differently.
> >
> > That sounds like the activation protocol should be made part of D-Bus (not of
> > systemd or upstart), with strings starting with "org.freedesktop.DBus".
> >
> I think that makes far more sense in the long-term, I'd be more than
> happy to support such a thing in Upstart.  We should make sure the
> protocol is flexible enough that it doesn't limit implementations to
> one particular way of working.
> Obviously this protocol should require the Init daemon be connected to
> the bus, how would such an init daemon register with the bus daemon?

This has been solved already with the systemd/dbus glue. Unless you can
point me to some brokeness in that scheme I see little reaso to reopen
this discussion.

> But to Lennart I think it made more sense for it to be a Signal, I'm
> not sure of his rationale - Lennart?  One advantage would be that you
> could just broadcast such a thing, but then you have no guarantee of a
> returning error, etc.

Scotty, we discussed that when I originally posted my patches. Please
grep through the archives.

The main point was that in the normal case a reply is unnecessary, since
the arrival of the activated service on the bus should be enough
indication of success. But there was more.

> Other init daemons might foreseeably want other members of the
> activation file?  Perhaps the right approach would be to include all
> of the members of the ini file in the message so that the init daemon
> can make its own call as to which it uses.  (It might not even have
> its own configuration, it might simply use the Exec= line itself).

I find supproting two init systems already one more than enough. I see
little point in thinking too much about who else might want to join the

> Thoughts?

Actually, I like the current scheme very much, and I don't even think it
would be necessary to change the proto at all. Whether a message is
called "systemd" or "upstart" doesn't really matter, does it? That the
message contents is slightly different (name of the dbus service instead
of name of the systemd service) effectively matters very little I believe.

> Lennart, would you be happy to move the activation protocol definition
> into the D-Bus Spec and implement that in systemd as well?

Scotty, no I don't think we should do that. The D-Bus spec exists to
allow reimplementation of compatible clients or servers for the D-Bus
proocol and for that describes the interaction between clients and
servers. However, the activation stuff is an interface between one
particular implementation of the server, and one or two particular
implementations of init systems. I think it would be smart to leave this
a private protocol between three parties instead of declaring it
something super-official that is useable for everybody else too which
would greatly complicate changing it. And that is actually something
very much in your own interest I believe.


Lennart Poettering - Red Hat, Inc.

More information about the dbus mailing list