Re: Notify enhancement
От | Alvaro Herrera |
---|---|
Тема | Re: Notify enhancement |
Дата | |
Msg-id | 20061215212627.GU14237@alvh.no-ip.org обсуждение исходный текст |
Ответ на | Re: Notify enhancement (Andrew Dunstan <andrew@dunslane.net>) |
Ответы |
Re: Notify enhancement
|
Список | pgsql-hackers |
Andrew Dunstan wrote: > I don't understand how we decide that everybody who needs a given > event+message has got it, if we don't know who (if anyone) is listening? > How do we decide that we no longer need the info in the shmem buffer? Keep a pointer in shared memory for each listener backend, saying how far it has scanned the ring? There would be a single writing pointer, so it's trivial to see when the ring is "full". > Timeout? sinval issues a reset if the buffer becomes full, but we can't > do that here. Just have NOTIFY block when the buffer is full, and maybe issue a warning so that the user knows that he should increase the ring size. > Are we keeping use of SIGUSR2 in this scheme? What for? Just protect the write pointer with a lwlock and have listeners check whether somebody has written something.
В списке pgsql-hackers по дате отправления: