When changing owner of a subscription, do not throw an error.

Errors will be caught when the connection is actually used.

Restore uses multiple DDL commands to restore a subscription, so
checks of the intermediate state risk restore errors. In the future we
could address this with a more careful restoration order, but the
DDL-time errors are merely for convenience.

Addresses finding 2 in the report from the linked discussion.

Reported-by: Noah Misch <[email protected]>
Reviewed-by: Shlok Kyal <[email protected]>
Reviewed-by: Amit Kapila <[email protected]>
Discussion: https://postgr.es/m/20260710195902.4f.noahmisch%40microsoft.com
Discussion: 
https://postgr.es/m/[email protected]
Backpatch-through: 19

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/7f4fb058076a8294933efa9f40378cbfb3b89ffd

Modified Files
--------------
src/backend/commands/subscriptioncmds.c    | 24 +++++++-----------------
src/test/regress/expected/subscription.out |  5 +++++
src/test/regress/sql/subscription.sql      |  4 ++++
3 files changed, 16 insertions(+), 17 deletions(-)

Reply via email to