Re: [HACKERS] Testlib.pm vs msys

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема Re: [HACKERS] Testlib.pm vs msys
Дата
Msg-id 37d462e3-3fdc-ba43-887f-017e14934c01@2ndQuadrant.com
обсуждение исходный текст
Ответ на Re: [HACKERS] Testlib.pm vs msys  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: [HACKERS] Testlib.pm vs msys  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers

On 07/24/2017 09:33 PM, Tom Lane wrote:
>
> [good theory about why pg_ctl hangs in TAP test]
>
> Now, this theory still has a Mack-truck-sized hole in it, which is
> if that's the failure mechanism then why isn't it 100% effective?
> Seems like the TAP test should fail every time, if this is a full
> description.  But maybe it's part of the answer, so it seems worth
> experimenting in this direction.


The test that hangs is the only case where we call pg_ctl via
command_like. If we use other mechanisms such as command_ok that don't
try to read the output there is no problem.

Another data point is that this test doesn't hang on bowerbird, which is
an animal on the same machine but doing an MSVC build. Thus my thesis
that it's probably to do with the imteraction with the MSys perl and shell.

A simple workaround might be to provide two flavors of command_like, one
that uses files it then slurps in and one that uses direct scalars and
EOF detection.

cheers

andrew


>
> A bit of googling Microsoft's documentation suggests that maybe all
> we have to do is pass CreateProcessAsUser's bInheritHandles parameter
> as FALSE not TRUE in pg_ctl.c.  It's not apparent to me that there
> are any handles we do need the CMD process to inherit.
>
>             


Maybe.

cheers

andrew


-- 
Andrew Dunstan                https://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services




В списке pgsql-hackers по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [HACKERS] estimation for join results cardinality is sometimes more than the product of the downstream nodes'
Следующее
От: Tom Lane
Дата:
Сообщение: Re: [HACKERS] pl/perl extension fails on Windows