Re: Listen / Notify rewrite

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Listen / Notify rewrite
Дата
Msg-id 9378.1257987810@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Listen / Notify rewrite  (Andrew Chernow <ac@esilo.com>)
Ответы Re: Listen / Notify rewrite
Список pgsql-hackers
Andrew Chernow <ac@esilo.com> writes:
> +  * This function is executed for every notification found in the queue in order
> +  * to check if the current backend is listening on that channel. Not sure if we
> +  * should further optimize this, for example convert to a sorted array and
> +  * allow binary search on it...

> I think a bsearch would be needed.  Very busy servers that make heavy use of 
> notifies would be quite a penalty.

Premature optimization is the root of all evil ;-).  Unless you've done
some profiling and can show that this is a hot spot, making it more
complicated isn't the thing to be doing now.
        regards, tom lane


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

Предыдущее
От: Andrew Chernow
Дата:
Сообщение: Re: Listen / Notify rewrite
Следующее
От: Itagaki Takahiro
Дата:
Сообщение: Re: Partitioning option for COPY