pistacheio / pistache

A high-performance REST toolkit written in C++
https://pistacheio.github.io/pistache/
Apache License 2.0
3.21k stars 701 forks source link

SystemD Socket activation support #1248

Open jacky309 opened 1 month ago

jacky309 commented 1 month ago

I would like my server to be socket-activatable (see https://0pointer.de/blog/projects/socket-activation.html). The trick is to use a file descriptor which has already been open by SystemD, rather than creating the server socket by ourselves. As far as I have seen, Pistache does not provide an API which enables passing an existing file descriptor. Is that right ?

kiplingw commented 1 month ago

On Tue, 2024-10-08 at 03:26 -0700, jacky309 wrote:

I would like my server to be socket-activatable (see https://0pointer.de/blog/projects/socket-activation.html). The trick is to use a file descriptor which has already been open by SystemD, rather than creating the server socket by ourselves. As far as I have seen, Pistache does not provide an API which enables passing an existing file descriptor. Is that right ?

It does not. But that's an interesting idea and a PR we would certainly look at.

-- Kip Warner OpenPGP signed/encrypted mail preferred https://www.thevertigo.com