]> granicus.if.org Git - postgresql/commit
Remove the NODROP SLOT option from DROP SUBSCRIPTION
authorPeter Eisentraut <peter_e@gmx.net>
Tue, 9 May 2017 14:20:42 +0000 (10:20 -0400)
committerPeter Eisentraut <peter_e@gmx.net>
Tue, 9 May 2017 14:20:42 +0000 (10:20 -0400)
commit013c1178fd0adefa0f68d5ce2d84e7ae6f9613a1
treec1d81aeda68bec07b67c317617b40cbc8ea2e925
parentc4c493fd3581dfbce45e903b87e12eea508f47e4
Remove the NODROP SLOT option from DROP SUBSCRIPTION

It turned out this approach had problems, because a DROP command should
not have any options other than CASCADE and RESTRICT.  Instead, always
attempt to drop the slot if there is one configured, but also add an
ALTER SUBSCRIPTION action to set the slot to NONE.

Author: Petr Jelinek <petr.jelinek@2ndquadrant.com>
Reported-by: Tom Lane <tgl@sss.pgh.pa.us>
Discussion: https://www.postgresql.org/message-id/29431.1493730652@sss.pgh.pa.us
20 files changed:
doc/src/sgml/ref/create_subscription.sgml
doc/src/sgml/ref/drop_subscription.sgml
src/backend/catalog/pg_subscription.c
src/backend/commands/subscriptioncmds.c
src/backend/nodes/copyfuncs.c
src/backend/nodes/equalfuncs.c
src/backend/parser/gram.y
src/backend/replication/logical/worker.c
src/bin/psql/tab-complete.c
src/include/catalog/catversion.h
src/include/catalog/pg_subscription.h
src/include/nodes/parsenodes.h
src/include/parser/kwlist.h
src/test/modules/dummy_seclabel/expected/dummy_seclabel.out
src/test/modules/dummy_seclabel/sql/dummy_seclabel.sql
src/test/regress/expected/object_address.out
src/test/regress/expected/subscription.out
src/test/regress/sql/object_address.sql
src/test/regress/sql/subscription.sql
src/test/subscription/t/001_rep_changes.pl