Re: Using PQexecQuery in pipeline mode produces unexpected Close messages

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Using PQexecQuery in pipeline mode produces unexpected Close messages
Дата
Msg-id 532816.1655319402@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Using PQexecQuery in pipeline mode produces unexpected Close messages  (Alvaro Herrera <alvherre@alvh.no-ip.org>)
Ответы Re: Using PQexecQuery in pipeline mode produces unexpected Close messages  (Kyotaro Horiguchi <horikyota.ntt@gmail.com>)
Список pgsql-hackers
Alvaro Herrera <alvherre@alvh.no-ip.org> writes:
> So, git archaeology led me to this thread
> https://postgr.es/m/202106072107.d4i55hdscxqj@alvherre.pgsql
> which is why we added that message in the first place.

Um.  Good thing you looked.  I doubt we want to revert that change now.

> Alternatives:
> - Have the client not complain if it gets CloseComplete in idle state.
>   (After all, it's a pretty useless message, since we already do nothing
>   with it if we get it in BUSY state.)

ISTM the actual problem here is that we're reverting to IDLE state too
soon.  I didn't try to trace down exactly where that's happening, but
I notice that in the non-pipeline case we don't go to IDLE till we've
seen 'Z' (Sync).  Something in the pipeline logic must be jumping the
gun on that state transition.

            regards, tom lane



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

Предыдущее
От: "Imseih (AWS), Sami"
Дата:
Сообщение: [PROPOSAL] Detecting plan changes with plan_id in pg_stat_activity
Следующее
От: Tom Lane
Дата:
Сообщение: Re: pg_upgrade (12->14) fails on aggregate