Re: listen/notify argument (old topic revisited)
От | Hannu Krosing |
---|---|
Тема | Re: listen/notify argument (old topic revisited) |
Дата | |
Msg-id | 1025712574.23475.80.camel@taru.tm.ee обсуждение исходный текст |
Ответ на | Re: listen/notify argument (old topic revisited) (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: listen/notify argument (old topic revisited)
|
Список | pgsql-hackers |
On Wed, 2002-07-03 at 16:30, Tom Lane wrote: > Hannu Krosing <hannu@tm.ee> writes: > > There could a little more smartness here to avoid unneccessary copying > > (not just storing) of not-listened-to data. > > Yeah, I was wondering about that too. > > > I guess that depending on the circumstances this can be either faster or > > slower than copying them all in one memmove. > > The more interesting question is whether it's better to hold the read > lock on the shared buffer for the minimum possible amount of time; OTOH, we may decide that getting a notify ASAP is not a priority and just go on doing what we did before if we can't get the lock and try again the next time around. This may have some pathological behaviours (starving some backends who always come late ;), but we are already attracting a thundering herd by sending a signal to all _possibly_ interested backends at the same time time. Keeping a list of who listens to what can solve this problem (but only in case of sparse listening habits). ----------------- Hannu
В списке pgsql-hackers по дате отправления: