]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/core/scope.c
core: whenever we change state of a unit, force out PropertiesChanged bus signal
authorLennart Poettering <lennart@poettering.net>
Tue, 27 Nov 2018 19:15:45 +0000 (20:15 +0100)
committerLennart Poettering <lennart@poettering.net>
Sat, 1 Dec 2018 11:53:26 +0000 (12:53 +0100)
commit6fcbec6f9b15e534badd069610e35f4c5303c502
tree22505234e50866f760c672e4913e250da8cea3b2
parent37d0b962eff19234d0b485c14b007081d2067ab9
core: whenever we change state of a unit, force out PropertiesChanged bus signal

This allows clients to follow our internal state changes safely.

Previously, quick state changes (for example, when we restart a unit due
to Restart= after it quickly transitioned through DEAD/FAILED states)
would be coalesced into one bus signal event, with this change there's
the guarantee that all state changes after the unit was announced ones
are reflected on th bus.

Note we only do this kind of guaranteed flushing only for unit state
changes, not for other unit property changes, where clients still have
to expect coalescing. This is because the unit state is a very
important, high-level concept.

Fixes: #10185
13 files changed:
src/core/automount.c
src/core/dbus-unit.c
src/core/dbus-unit.h
src/core/device.c
src/core/mount.c
src/core/path.c
src/core/scope.c
src/core/service.c
src/core/slice.c
src/core/socket.c
src/core/swap.c
src/core/target.c
src/core/timer.c