Re: [HACKERS] max backends checking patch
| От | Tom Lane |
|---|---|
| Тема | Re: [HACKERS] max backends checking patch |
| Дата | |
| Msg-id | 9309.915988074@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Re: [HACKERS] max backends checking patch (Tatsuo Ishii <t-ishii@sra.co.jp>) |
| Список | pgsql-hackers |
Tatsuo Ishii <t-ishii@sra.co.jp> writes:
>> Couldn't postmaster just keep # of backends running
>> in some variable, instead of examining BackendList ?
> Yes, you could do that way. I just want to keep things simple.
> Seems a seed of "maintenance problem" in the future IMHO:-)
I agree with Tatsuo. Counting the children once per backend startup
is certainly not a performance bottleneck, so there is no reason to
add complexity and a source of potential bugs to speed it up.
> Having a counter inside the dllist module is another idea. If there
> were many codes in the backend that counting elemnts in the dllist,
> this would be worth to think about.
That would be reasonable if justified by usage --- the tradeoff is
the added cost of maintaining the count for every dllist, whether or
not it's ever asked for...
regards, tom lane
В списке pgsql-hackers по дате отправления: