Re: Some 9.5beta2 backend processes not terminating properly? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Some 9.5beta2 backend processes not terminating properly?
Date
Msg-id 12844.1451765502@sss.pgh.pa.us
Whole thread Raw
In response to Re: Some 9.5beta2 backend processes not terminating properly?  (Andres Freund <andres@anarazel.de>)
Responses Re: Some 9.5beta2 backend processes not terminating properly?  (Andres Freund <andres@anarazel.de>)
List pgsql-hackers
Andres Freund <andres@anarazel.de> writes:
> I found a few more resources confirming that FD_CLOSE is edge
> triggered. Which probably doesn't just make our code buggy when waiting
> twice on the same socket, but probably also makes it very timing
> dependent: As the event is only triggered when the close actually occurs
> it's possible that we don't have any event associated with that socket:
> We only do so for shorts amount of time in WaitLatchOrSocket() and
> pgwin32_waitforsinglesocket().

Does the timing dependence explain why we've not been able to trigger this
by killing psql?

If the bug only occurs when the client connection drops when we're not
waiting for input, that would likely explain why nobody noticed it for
ten months.
        regards, tom lane



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Fwd: Core dump with nested CREATE TEMP TABLE
Next
From: Andres Freund
Date:
Subject: Re: Some 9.5beta2 backend processes not terminating properly?