Re: remove some STATUS_* symbols

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: remove some STATUS_* symbols
Дата
Msg-id 3a4550d0-e899-b477-fd43-0745d18a4fc1@2ndquadrant.com
обсуждение исходный текст
Ответ на Re: remove some STATUS_* symbols  (Robert Haas <robertmhaas@gmail.com>)
Ответы Re: remove some STATUS_* symbols  (Michael Paquier <michael@paquier.xyz>)
Список pgsql-hackers
On 2020-01-16 13:56, Robert Haas wrote:
> On Thu, Jan 16, 2020 at 12:50 AM Michael Paquier <michael@paquier.xyz> wrote:
>> Thanks, that looks fine.  I am still not sure whether the second patch
>> adding an enum via ProcWaitStatus improves the code readability
>> though, so my take would be to discard it for now.  Perhaps others
>> think differently, I don't know.
> 
> IMHO, custom enums for each particular case would be a big improvement
> over supposedly-generic STATUS codes. It makes it clearer which values
> are possible in each code path, and it comes out nicer in the
> debugger, too.

Given this feedback, I would like to re-propose the original patch, 
attached again here.

After this, the use of the remaining STATUS_* symbols will be contained 
to the frontend and backend libpq code, so it'll be more coherent.

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Вложения

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

Предыдущее
От: Ranier Vilela
Дата:
Сообщение: Re: Windows regress fails (latest HEAD)
Следующее
От: Li Japin
Дата:
Сообщение: Re: Terminate the idle sessions