| От | Martijn van Oosterhout |
|---|---|
| Тема | Re: LISTEN / NOTIFY |
| Дата | |
| Msg-id | 20061208144800.GI25912@svana.org обсуждение |
| Ответ на | LISTEN / NOTIFY (Hannes Dorbath <light@theendofthetunnel.de>) |
| Список | pgsql-general |
On Fri, Dec 08, 2006 at 03:38:49PM +0100, Hannes Dorbath wrote: > Is there a way I can have notifications to be streamed to the listener, > so I don't need to poll with LISTEN? > > LISTEN foo; > LISTEN > NOTIFY foo; > NOTIFY > Asynchronous notification "foo" received from server process with PID 3593. > > This does work for the same backend, but not for notifications issued > from another one. AIUI they are, it's just that the client needs to be looking for incoming data. If you're using psql for example, I don't beleive it checks for incoming data until you send a command. How you actually acheive that in your code is a seperate question and depends on the language you're using. Have a nice day, -- Martijn van Oosterhout <kleptog@svana.org> http://svana.org/kleptog/ > From each according to his ability. To each according to his ability to litigate.
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера