Re: Transaction callback

Поиск
Список
Период
Сортировка
От Jorge Godoy
Тема Re: Transaction callback
Дата
Msg-id 87fyabkc02.fsf@gmail.com
обсуждение исходный текст
Ответ на Re: Transaction callback  (Kevin Field <kev@brantaero.com>)
Список pgsql-general
Kevin Field <kev@brantaero.com> writes:

> http://archives.postgresql.org/pgsql-hackers/2004-01/msg00861.php
>
> (Just to dredge up another old thread...)
>
>> While its true that a post-commit operation cannot modify a database, it
>> might still for instance propagate the outcome of the transaction to another
>> resource outside of the database, it might invalidate a transaction local
>> in-memory cache, or it might clear resources occupied in memory for a rule
>> system, etc.
>
> This is exactly what I'd like to do.  Is there a way to do it nowadays? What
> I'm going for is an AJAX app that doesn't need to poll the server, but rather
> can have the server callback to it when a transaction messes with the data a
> user at which a user is looking.
>
> Any advice would be much appreciated.

I believe that you'll be wanting to take a look at the NOTIFY and LISTEN
commands.

http://www.postgresql.org/docs/8.1/interactive/sql-notify.html
http://www.postgresql.org/docs/8.1/interactive/sql-listen.html


Be seeing you,
--
Jorge Godoy      <jgodoy@gmail.com>

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

Предыдущее
От: "carter ck"
Дата:
Сообщение: Re: Improve Postgres Query Speed
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: Improve Postgres Query Speed