agora inbox for pgsql-sql@postgresql.org
help / color / mirror / Atom feeddoes the notification of postgres appear in transaction completed order
2+ messages / 2 participants
[nested] [flat]
* does the notification of postgres appear in transaction completed order
@ 2018-03-16 13:42 abctevez <swqshapu@163.com>
2018-03-16 14:57 ` Re: does the notification of postgres appear in transaction completed order Tom Lane <tgl@sss.pgh.pa.us>
0 siblings, 1 reply; 2+ messages in thread
From: abctevez @ 2018-03-16 13:42 UTC (permalink / raw)
To: pgsql-sql
I want to use notify/listen to catch the message that a transaction completed.Fire notify in trigger and as the official said, it won't notify if transaction rollback.However, I am wondering if the message appear in the same order with transaction execution.I couldn't find this topic on the official web or just I missed it?
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: does the notification of postgres appear in transaction completed order
2018-03-16 13:42 does the notification of postgres appear in transaction completed order abctevez <swqshapu@163.com>
@ 2018-03-16 14:57 ` Tom Lane <tgl@sss.pgh.pa.us>
0 siblings, 0 replies; 2+ messages in thread
From: Tom Lane @ 2018-03-16 14:57 UTC (permalink / raw)
To: abctevez <swqshapu@163.com>; +Cc: pgsql-sql
abctevez <swqshapu@163.com> writes:
> I want to use notify/listen to catch the message that a transaction completed.Fire notify in trigger and as the official said, it won't notify if transaction rollback.However, I am wondering if the message appear in the same order with transaction execution.I couldn't find this topic on the official web or just I missed it?
https://www.postgresql.org/docs/current/static/sql-notify.html
says
Except for dropping later instances of duplicate notifications, NOTIFY
guarantees that notifications from the same transaction get delivered
in the order they were sent. It is also guaranteed that messages from
different transactions are delivered in the order in which the
transactions committed.
regards, tom lane
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2018-03-16 14:57 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2018-03-16 13:42 does the notification of postgres appear in transaction completed order abctevez <swqshapu@163.com>
2018-03-16 14:57 ` Tom Lane <tgl@sss.pgh.pa.us>
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox