pg.ddx.io pgsql-committers@postgresql.org mailing list archive
help / color / mirror / Atom feedpgsql: Fix pg_identify_object_as_address() with event triggers
8+ messages / 2 participants
[nested] [flat]
Commits from this thread:
2021-04-28 f93f0b5b25 a928297bc6 85a3e0be1e 669f736666 b797918d27 0d05a3a1df Fix use-after-release issue with pg_identify_object_as_address()
* pgsql: Fix pg_identify_object_as_address() with event triggers
@ 2021-04-28 02:19 Michael Paquier <michael@paquier.xyz>
0 siblings, 0 replies; 8+ messages in thread
From: Michael Paquier @ 2021-04-28 02:19 UTC (permalink / raw)
To: pgsql-committers@lists.postgresql.org
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
Branch
------
REL_10_STABLE
Details
-------
https://git.postgresql.org/pg/commitdiff/90c9bad307bfabc3a397826349af76b4ca140aca
Modified Files
--------------
src/backend/catalog/objectaddress.c | 11 +++++------
src/test/regress/expected/event_trigger.out | 17 +++++++++++++++++
src/test/regress/sql/event_trigger.sql | 11 +++++++++++
3 files changed, 33 insertions(+), 6 deletions(-)
^ permalink raw reply [nested|flat] 8+ messages in thread
* pgsql: Fix pg_identify_object_as_address() with event triggers
@ 2021-04-28 02:19 Michael Paquier <michael@paquier.xyz>
0 siblings, 1 reply; 8+ messages in thread
From: Michael Paquier @ 2021-04-28 02:19 UTC (permalink / raw)
To: pgsql-committers@lists.postgresql.org
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
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/f7aab36d61fd2fdbd949d5880247e8cae9ee4be0
Modified Files
--------------
src/backend/catalog/objectaddress.c | 11 +++++------
src/test/regress/expected/event_trigger.out | 17 +++++++++++++++++
src/test/regress/sql/event_trigger.sql | 11 +++++++++++
3 files changed, 33 insertions(+), 6 deletions(-)
^ permalink raw reply [nested|flat] 8+ messages in thread
* pgsql: Fix pg_identify_object_as_address() with event triggers
@ 2021-04-28 02:19 Michael Paquier <michael@paquier.xyz>
0 siblings, 0 replies; 8+ messages in thread
From: Michael Paquier @ 2021-04-28 02:19 UTC (permalink / raw)
To: pgsql-committers@lists.postgresql.org
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
Branch
------
REL_11_STABLE
Details
-------
https://git.postgresql.org/pg/commitdiff/5b717e13c90bf281b7cc65eefd032c8bf54c3448
Modified Files
--------------
src/backend/catalog/objectaddress.c | 11 +++++------
src/test/regress/expected/event_trigger.out | 17 +++++++++++++++++
src/test/regress/sql/event_trigger.sql | 11 +++++++++++
3 files changed, 33 insertions(+), 6 deletions(-)
^ permalink raw reply [nested|flat] 8+ messages in thread
* pgsql: Fix pg_identify_object_as_address() with event triggers
@ 2021-04-28 02:19 Michael Paquier <michael@paquier.xyz>
0 siblings, 0 replies; 8+ messages in thread
From: Michael Paquier @ 2021-04-28 02:19 UTC (permalink / raw)
To: pgsql-committers@lists.postgresql.org
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
Branch
------
REL_12_STABLE
Details
-------
https://git.postgresql.org/pg/commitdiff/7e76cb1d82bcc2d39a3d70930822c247d6a034d8
Modified Files
--------------
src/backend/catalog/objectaddress.c | 11 +++++------
src/test/regress/expected/event_trigger.out | 17 +++++++++++++++++
src/test/regress/sql/event_trigger.sql | 11 +++++++++++
3 files changed, 33 insertions(+), 6 deletions(-)
^ permalink raw reply [nested|flat] 8+ messages in thread
* pgsql: Fix pg_identify_object_as_address() with event triggers
@ 2021-04-28 02:19 Michael Paquier <michael@paquier.xyz>
0 siblings, 0 replies; 8+ messages in thread
From: Michael Paquier @ 2021-04-28 02:19 UTC (permalink / raw)
To: pgsql-committers@lists.postgresql.org
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
Branch
------
REL9_6_STABLE
Details
-------
https://git.postgresql.org/pg/commitdiff/6e41ff0562d3e1a5a88c826b0aa0b8f20bc92763
Modified Files
--------------
src/backend/catalog/objectaddress.c | 11 +++++------
src/test/regress/expected/event_trigger.out | 15 +++++++++++++++
src/test/regress/sql/event_trigger.sql | 9 +++++++++
3 files changed, 29 insertions(+), 6 deletions(-)
^ permalink raw reply [nested|flat] 8+ messages in thread
* pgsql: Fix pg_identify_object_as_address() with event triggers
@ 2021-04-28 02:19 Michael Paquier <michael@paquier.xyz>
0 siblings, 0 replies; 8+ messages in thread
From: Michael Paquier @ 2021-04-28 02:19 UTC (permalink / raw)
To: pgsql-committers@lists.postgresql.org
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
Branch
------
REL_13_STABLE
Details
-------
https://git.postgresql.org/pg/commitdiff/f3c4537876843bea9a9d35d9643d347750961848
Modified Files
--------------
src/backend/catalog/objectaddress.c | 11 +++++------
src/test/regress/expected/event_trigger.out | 17 +++++++++++++++++
src/test/regress/sql/event_trigger.sql | 11 +++++++++++
3 files changed, 33 insertions(+), 6 deletions(-)
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: pgsql: Fix pg_identify_object_as_address() with event triggers
@ 2021-04-28 02:44 Tom Lane <tgl@sss.pgh.pa.us>
parent: Michael Paquier <michael@paquier.xyz>
0 siblings, 1 reply; 8+ messages in thread
From: Tom Lane @ 2021-04-28 02:44 UTC (permalink / raw)
To: Michael Paquier <michael@paquier.xyz>; +Cc: pgsql-committers@lists.postgresql.org
Michael Paquier <michael@paquier.xyz> writes:
> Fix pg_identify_object_as_address() with event triggers
Looks like this has issues under RELCACHE_FORCE_RELEASE
and/or CATCACHE_FORCE_RELEASE:
https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=prion&dt=2021-04-28%2002%3A28%3A04
regards, tom lane
^ permalink raw reply [nested|flat] 8+ messages in thread
* Re: pgsql: Fix pg_identify_object_as_address() with event triggers
@ 2021-04-28 02:57 Michael Paquier <michael@paquier.xyz>
parent: Tom Lane <tgl@sss.pgh.pa.us>
0 siblings, 0 replies; 8+ messages in thread
From: Michael Paquier @ 2021-04-28 02:57 UTC (permalink / raw)
To: Tom Lane <tgl@sss.pgh.pa.us>; +Cc: pgsql-committers@lists.postgresql.org
On Tue, Apr 27, 2021 at 10:44:08PM -0400, Tom Lane wrote:
> Looks like this has issues under RELCACHE_FORCE_RELEASE
> and/or CATCACHE_FORCE_RELEASE:
>
> https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=prion&dt=2021-04-28%2002%3A28%3A04
Yes, this is missing a pstrdup() for the event trigger name. I was
just working on it.
--
Michael
Attachments:
signature.asc (application/pgp-signature, 832B) download
^ permalink raw reply [nested|flat] 8+ messages in thread
end of thread, other threads:[~2021-04-28 02:57 UTC | newest]
Thread overview: 8+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2021-04-28 02:19 pgsql: Fix pg_identify_object_as_address() with event triggers Michael Paquier <michael@paquier.xyz>
2021-04-28 02:44 ` Tom Lane <tgl@sss.pgh.pa.us>
2021-04-28 02:57 ` Michael Paquier <michael@paquier.xyz>
2021-04-28 02:19 pgsql: Fix pg_identify_object_as_address() with event triggers Michael Paquier <michael@paquier.xyz>
2021-04-28 02:19 pgsql: Fix pg_identify_object_as_address() with event triggers Michael Paquier <michael@paquier.xyz>
2021-04-28 02:19 pgsql: Fix pg_identify_object_as_address() with event triggers Michael Paquier <michael@paquier.xyz>
2021-04-28 02:19 pgsql: Fix pg_identify_object_as_address() with event triggers Michael Paquier <michael@paquier.xyz>
2021-04-28 02:19 pgsql: Fix pg_identify_object_as_address() with event triggers Michael Paquier <michael@paquier.xyz>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox