chiark / gitweb /
sd-bus: optionally, use inotify to wait for bus sockets to appear
authorLennart Poettering <lennart@poettering.net>
Fri, 15 Dec 2017 21:24:52 +0000 (22:24 +0100)
committerSven Eden <yamakuzure@gmx.net>
Wed, 30 May 2018 05:49:55 +0000 (07:49 +0200)
commit004bb7654fb0ca644e70ae22221adfecdcb4a8ed
tree7163c295455c55b82b02e6d1c372a8f3423f9a18
parent5295adaf6b864f44b0f6ad8ec5aeda540d9c236e
sd-bus: optionally, use inotify to wait for bus sockets to appear

This adds a "watch-bind" feature to sd-bus connections. If set and the
AF_UNIX socket we are connecting to doesn't exist yet, we'll establish
an inotify watch instead, and wait for the socket to appear. In other
words, a missing AF_UNIX just makes connecting slower.

This is useful for daemons such as networkd or resolved that shall be
able to run during early-boot, before dbus-daemon is up, and want to
connect to dbus-daemon as soon as it becomes ready.
src/libelogind/libelogind.sym
src/libelogind/sd-bus/bus-internal.h
src/libelogind/sd-bus/bus-socket.c
src/libelogind/sd-bus/bus-socket.h
src/libelogind/sd-bus/sd-bus.c
src/libelogind/sd-bus/test-bus-watch-bind.c [new file with mode: 0644]
src/systemd/sd-bus.h
src/test/meson.build