aboutsummaryrefslogtreecommitdiff
path: root/src/include/common/jsonapi.h
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2024-06-20 14:21:36 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2024-06-20 14:21:36 -0400
commite6d0d16adf7fb7e715314d5068db4b875c3edf00 (patch)
tree691bab6f4fb8bb951dbacb0c157f5287a3bff017 /src/include/common/jsonapi.h
parentab4346ebbfef44db857321d74bc0c31e03a72514 (diff)
downloadpostgresql-e6d0d16adf7fb7e715314d5068db4b875c3edf00.tar.gz
postgresql-e6d0d16adf7fb7e715314d5068db4b875c3edf00.zip
Don't throw an error if a queued AFTER trigger no longer exists.
afterTriggerInvokeEvents and AfterTriggerExecute have always treated it as an error if the trigger OID mentioned in a queued after-trigger event can't be found. However, that fails to account for the edge case where the trigger's been dropped in the current transaction since queueing the event. There seems no very good reason to disallow that case, so instead silently do nothing if the trigger OID can't be found. This does give up a little bit of bug-detection ability, but I don't recall that these error messages have ever actually revealed a bug, so it seems mostly theoretical. Alternatives such as marking pending events DONE at the time of dropping a trigger would be complicated and perhaps introduce bugs of their own. Per bug #18517 from Alexander Lakhin. Back-patch to all supported branches. Discussion: https://postgr.es/m/18517-af2d19882240902c@postgresql.org
Diffstat (limited to 'src/include/common/jsonapi.h')
0 files changed, 0 insertions, 0 deletions