Re: zombie connections

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: zombie connections
Дата
Msg-id CA+TgmoZPV+jP3+CceKtAmjgR4j1Q2JLT2=n1R1irBfcVWJWCMg@mail.gmail.com
обсуждение исходный текст
Ответ на Re: zombie connections  (Isaac Morland <isaac.morland@gmail.com>)
Список pgsql-hackers
On Fri, Apr 3, 2020 at 9:52 AM Isaac Morland <isaac.morland@gmail.com> wrote:
> Does it make any difference if the query is making changes? If the query is just computing a result and returning it
tothe client, there is no point in continuing once the socket is closed. But if it is updating data or making DDL
changes,then at least some of the time it would be preferable for the changes to be made. Having said that, in normal
operationone wants, at the client end, to see the message from the server that the changes have been completed, not
justfire off a change and hope it completes. 

The system can't know whether the query is going to change anything,
because even if the query is a SELECT, it doesn't know whether any of
the functions or operators called from that SELECT might write data.

I don't think it would be smart to make behavior like this depend on
whether the statement is a SELECT vs. INSERT/UPDATE/DELETE, or on
things like whether there is an explicit transaction open. I think we
should just have a feature that kills the server process if the
connection goes away. If some people don't want that, it can be
optional.

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



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

Предыдущее
От: Isaac Morland
Дата:
Сообщение: Re: zombie connections
Следующее
От: Pavel Stehule
Дата:
Сообщение: Re: zombie connections