]> git.ipfire.org Git - thirdparty/postgresql.git/commit
Fix pg_identify_object_as_address() with event triggers
authorMichael Paquier <michael@paquier.xyz>
Wed, 28 Apr 2021 02:18:33 +0000 (11:18 +0900)
committerMichael Paquier <michael@paquier.xyz>
Wed, 28 Apr 2021 02:18:33 +0000 (11:18 +0900)
commit6e41ff0562d3e1a5a88c826b0aa0b8f20bc92763
tree18539d33a79b7a38b60007a101cffa0ffc3118d4
parentb391db4943dce0688635b9e6550af22a4dac96ed
Fix pg_identify_object_as_address() with event triggers

Attempting to use this function with event triggers failed, as, since
its introduction in a676201, this code has never associated an object
name with event triggers.  This addresses the failure by adding the
event trigger name to the set defining its object address.

Note that regression tests are added within event_trigger and not
object_address to avoid issues with concurrent connections in parallel
schedules.

Author: Joel Jacobson
Discussion: https://postgr.es/m/3c905e77-a026-46ae-8835-c3f6cd1d24c8@www.fastmail.com
Backpatch-through: 9.6
src/backend/catalog/objectaddress.c
src/test/regress/expected/event_trigger.out
src/test/regress/sql/event_trigger.sql