public inbox for [email protected]  
help / color / mirror / Atom feed
From: Michael Paquier <[email protected]>
To: Hayato Kuroda (Fujitsu) <[email protected]>
Cc: '[email protected]' <[email protected]>
Subject: Re: ReplicationSlotRelease() crashes when the instance is in the single user mode
Date: Tue, 18 Feb 2025 16:50:22 +0900
Message-ID: <[email protected]> (raw)
In-Reply-To: <OSCPR01MB149669EF7D087A588773B7E04F5FA2@OSCPR01MB14966.jpnprd01.prod.outlook.com>
References: <OSCPR01MB14966ED588A0328DAEBE8CB25F5FA2@OSCPR01MB14966.jpnprd01.prod.outlook.com>
	<[email protected]>
	<OSCPR01MB149669EF7D087A588773B7E04F5FA2@OSCPR01MB14966.jpnprd01.prod.outlook.com>

On Tue, Feb 18, 2025 at 07:29:51AM +0000, Hayato Kuroda (Fujitsu) wrote:
> According to the original thread [1], there was a wide consensus replication-related
> operations can be rejected, except the slot removal. I feel this is reasonable.
> 
> Currently pg_drop_replication_slot() requires the droping slot can be acquired,
> so we cannot reject it in single user mode as-is. Maybe we should revive the 0002
> patch in [1] then try to do that. Thought?
> 
> [1]: https://www.postgresql.org/message-id/3b2f809f-326c-38dd-7a9e-897f957a4eb1%40enterprisedb.com

Ah, good point for the slot drop.  So 0ce5cf2ef24f is claiming that
some of these manipulations are OK.  I didn't suspect this one.

Slot advancing is a very different beast, unfortunately, that may
depend on many other subsystems.  For example with logical slots we
would finish by calling rm_decode, which could be outside of core.
Justifying that this operation is supported in single-user mode is
larger than what you are suggesting here..
--
Michael


Attachments:

  [application/pgp-signature] signature.asc (833B, ../[email protected]/2-signature.asc)
  download

view thread (31+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected]
  Subject: Re: ReplicationSlotRelease() crashes when the instance is in the single user mode
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox