[systemd-devel] [PATCH] core/socket: we only want one event on standard sockets

Shawn Landden shawn at churchofgit.com
Tue Nov 26 12:23:50 PST 2013


As we only reciece one event at a time, and dequeue it in the same go,
yeah ONESHOT won't change anything.

On Tue, Nov 26, 2013 at 9:33 AM, David Timothy Strauss
<david at davidstrauss.net> wrote:
> On Wed, Nov 27, 2013 at 2:32 AM, Lennart Poettering
> <lennart at poettering.net> wrote:
>> Well, but EPOLLET only works correctly if each time an event is
>> triggered we dispatch *all* possibly queued events on the fd, until
>> EAGAIN is read again. But we don't do that, heck, if Listen=no is used
>> we don''t even read a single incoming connection of the scket, we leave
>> that to the daemon we spawn, but we cannot trust that. So, I don't get
>> what EPOLLET is supposed to do good here?
>
> I should have more selectively quoted before answering. I was only
> trying to answer why we'd continue having poll for the socket fds
> after queuing the initial service. I was not trying to suggest EPOLLET
> is appropriate for the goal of lazy "distribute" process pool
> expansion. You've clearly correct about that.
I was worried that the fact that we never accept() the socket when using
distribute (now I am convinced we shouldn't use it otherwise)
would cause it to trigger multiple times for only one incoming connection,
if the spawned thread never entered accept() (or we raced it),
but reading this thread makes me think I don't fully understand the
semantics of EPOLLET.
> _______________________________________________
> systemd-devel mailing list
> systemd-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/systemd-devel


More information about the systemd-devel mailing list