Re: [w32] test_shm_mq test suite permanently burns connections slots

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Cc: Noah Misch <noah(at)leadboat(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [w32] test_shm_mq test suite permanently burns connections slots
Date: 2014-07-30 15:37:28
Message-ID: CA+Tgmob21iMFrQ4fwHAFDQm5dQ1nhMvC=uQOG7ATmENXbOuF3w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Jul 28, 2014 at 9:38 PM, Alvaro Herrera
<alvherre(at)2ndquadrant(dot)com> wrote:
> Robert Haas wrote:
>> OK, I think I see the problem. In EXEC_BACKEND mode,
>> SubPostmasterMain() calls InitProcess() before IsBackgroundWorker has
>> been set. InitProcess() therefore pulls the PGPROC for the worker
>> from freeProcs rather than bgworkerFreeProcs. By exit time,
>> IsBackgroundWorker has been set, so the PGPROC gets put back on the
>> bgworkerFreeProcs list. Eventually there are no regular PGPROCs left;
>> they've all been moved to the bgworkerFreeProcs list.
>
> Doh. I'm surprised -- I tested a worker that crashed over and over to
> ensure PGPROCs were reused sanely. I guess I forgot to run it under
> EXEC_BACKEND.
>
> Are you fixing it?

Working on it now.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2014-07-30 16:07:50 Re: BUG #10823: Better REINDEX syntax.
Previous Message Fabien COELHO 2014-07-30 15:26:15 Re: Distance from point to box