[systemd-devel] How to properly write an "umbrella" unit

Lennart Poettering lennart at poettering.net
Wed Jul 22 18:09:40 PDT 2015


On Thu, 23.07.15 10:41, Daurnimator (quae at daurnimator.com) wrote:

> On 23 July 2015 at 04:41, Lennart Poettering <lennart at poettering.net> wrote:
> > Maybe we can change the manager core to propagate Reload() calls
> > for unit type that do not support it natively to other units listed in
> > PropagateReloadsTo= and then become a NOP.
> >
> > Or in other words: invoking reload on a target that knows no
> > PropagateReloadsTo= should continue to return an error. But if such
> > deps are defined, it should become a silent NOP and propagate the
> > event.
> >
> > Could you file an RFP issue on github asking for this? [or even better,
> > send a PR with a patch...  ;-) ]
> 
> ReloadPropagatedFrom= would seem to be more useful here.

Well, ReloadPropagateFrom= is the inverse of PropagateReloadsTo=. If
there is a dep of the first kind from A to B, there's always a dep of
the second kind from B to A, and vice versa.

> Why should reloading a target error in the first place? ==> why not just a NOP?

Hides bugs? reloading a target makes no sense, unless you use it for
reload propagation. Hence we should generate an error.

Lennart

-- 
Lennart Poettering, Red Hat


More information about the systemd-devel mailing list