Tom Lane <tgl@xxxxxxxxxxxxx> writes: > I would still expect any reimplementation of notify messaging to honor the > principle that a LISTEN doesn't take effect till you commit. Otherwise, what > of > > BEGIN; > LISTEN foo; > ROLLBACK; > > ? If I get some events for foo after this I'd surely think it was > broken. Well the rollback would roll back any consequences of the notify handler firing too. So the transactional nature would still be maintained. I'm not sure why you're imagining that the listen would still be in effect after the rollback. rollback would return the connection state to the same state it was in before the transaction. I Think of GUC variables like enable_* as a good analogy. If you fiddle with them their effects are felt immediately by your transaction. You don't have to commit to make those changes take effect. If you roll back your changes their original state is restored. -- greg