Thread
Commits
-
Doc: mention that you can't PREPARE TRANSACTION after NOTIFY.
- e4fbf22831c2 11.0 landed
- f39fc2b27d2b 9.2.24 landed
- 7102efd9d71f 9.3.20 landed
- 7b233fce1bb6 10.1 landed
- 55429227ce20 9.4.15 landed
- 1c715f1713a0 9.5.10 landed
- 0ff56a59d249 9.6.6 landed
-
Prepare transaction doesn't mention NOTIFY
mark@inomial.com — 2017-10-24T01:06:02Z
The following documentation comment has been logged on the website: Page: https://www.postgresql.org/docs/10/static/sql-prepare-transaction.html Description: Hi, in prepare transaction documentation in PG10 and earlier, it says that you can't prepare a transaction with LISTEN or UNLISTEN but it doesn't mention NOTIFY. The NOTIFY documentation *does* mention that it won't work with PREPARE, so it's just that the explicit mention of LISTEN and not NOTIFY is confusing. I know this isn't the place to ask (and I'll never see the answer :) but I'm baffled by the lack of support for NOTIFY in prepared transactions, and it's causing me loads of grief, looks like I'm going to have to use a poll based solution over a large number of databases, which is really unfortunate in terms of resource utilisation.
-
Re: Prepare transaction doesn't mention NOTIFY
Tom Lane <tgl@sss.pgh.pa.us> — 2017-10-27T14:59:00Z
mark@inomial.com writes: > Hi, in prepare transaction documentation in PG10 and earlier, it says that > you can't prepare a transaction with LISTEN or UNLISTEN but it doesn't > mention NOTIFY. Yup, that's an oversight --- fixed. > I know this isn't the place to ask (and I'll never see the answer :) but I'm > baffled by the lack of support for NOTIFY in prepared transactions, The big problem is that we can't do anything at PREPARE time to guarantee that the NOTIFY will succeed. Admittedly, the queue is large enough that failure to insert the message isn't too likely, but "probably it will work" is not the semantics we want from PREPARE. regards, tom lane