mirror of
https://github.com/postgres/postgres.git
synced 2025-07-28 23:42:10 +03:00
Cleanup slots during drop database
Automatically drop all logical replication slots associated with a database when the database is dropped. Previously we threw an ERROR if a slot existed. Now we throw ERROR only if a slot is active in the database being dropped. Craig Ringer
This commit is contained in:
@ -18876,7 +18876,8 @@ postgres=# SELECT * FROM pg_walfile_name_offset(pg_stop_backup());
|
||||
<entry>
|
||||
Drops the physical or logical replication slot
|
||||
named <parameter>slot_name</parameter>. Same as replication protocol
|
||||
command <literal>DROP_REPLICATION_SLOT</>.
|
||||
command <literal>DROP_REPLICATION_SLOT</>. For logical slots, this must
|
||||
be called when connected to the same database the slot was created on.
|
||||
</entry>
|
||||
</row>
|
||||
|
||||
|
@ -2034,6 +2034,8 @@ The commands accepted in walsender mode are:
|
||||
<para>
|
||||
Drops a replication slot, freeing any reserved server-side resources. If
|
||||
the slot is currently in use by an active connection, this command fails.
|
||||
If the slot is a logical slot that was created in a database other than
|
||||
the database the walsender is connected to, this command fails.
|
||||
</para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
|
Reference in New Issue
Block a user