lucab / libsystemd-rs

A pure-Rust client library to work with systemd
https://crates.io/crates/libsystemd
Other
105 stars 19 forks source link

Reuse socket #89

Closed swsnr closed 2 years ago

swsnr commented 3 years ago

Closes #87

swsnr commented 3 years ago

@lucab Is this what you had in mind?

lucab commented 2 years ago

LGTM. I went back through my github history, and the reason for using an unconnected socket client-side is to cope with journald restarts, see https://github.com/coreos/go-systemd/pull/279. The native systemd C library does the same, see https://github.com/coreos/go-systemd/pull/218#issuecomment-274490875.

If we start exposing a way for consumers to provide a socket, we'll have to keep that in mind and check that it is a proper unbound one.

swsnr commented 2 years ago

Makes sense.

I've merged this pull request; can we make a new release?