v9-0002-Doc-configuration-file-handling-in-pg_createsubscrib.patch

text/x-patch

Filename: v9-0002-Doc-configuration-file-handling-in-pg_createsubscrib.patch
Type: text/x-patch
Part: 1
Message: Re: Resetting recovery target parameters in pg_createsubscriber
From daa7126c061f39f1e345fbb0e98b33db07366885 Mon Sep 17 00:00:00 2001
From: Alena Vinter <dlaaren8@gmail.com>
Date: Tue, 30 Dec 2025 14:12:06 +0700
Subject: [PATCH 2/2] Doc: configuration file handling in pg_createsubscriber

Update pg_createsubscriber.sgml to explain that recovery parameters are
written to a separate pg_createsubscriber.conf file included via
include_if_exists, and that the file is renamed to .disabled upon
completion or failure to prevent reloading on restart.
---
 doc/src/sgml/ref/pg_createsubscriber.sgml | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/doc/src/sgml/ref/pg_createsubscriber.sgml b/doc/src/sgml/ref/pg_createsubscriber.sgml
index e450c6a5b37..268fc414216 100644
--- a/doc/src/sgml/ref/pg_createsubscriber.sgml
+++ b/doc/src/sgml/ref/pg_createsubscriber.sgml
@@ -518,8 +518,11 @@ PostgreSQL documentation

     <step>
      <para>
-      Write recovery parameters into the target data directory and restart the
-      target server.  It specifies an LSN (<xref
+      Write recovery parameters into the separate configuration file
+      <filename>pg_createsubscriber.conf</filename> that is included from
+      <filename>postgresql.auto.conf</filename> using
+      <literal>include_if_exists</literal> in the target data directory, then
+      restart the target server.  It specifies an LSN (<xref
       linkend="guc-recovery-target-lsn"/>) of the write-ahead log location up
       to which recovery will proceed.  It also specifies
       <literal>promote</literal> as the action that the server should take
@@ -532,7 +535,10 @@ PostgreSQL documentation
       server ends standby mode and is accepting read-write transactions.  If
       <option>--recovery-timeout</option> option is set,
       <application>pg_createsubscriber</application> terminates if recovery
-      does not end until the given number of seconds.
+      does not end until the given number of seconds.  Upon completion or
+      failure, the included configuration file is renamed to
+      <filename>pg_createsubscriber.conf.disabled</filename> so it is no
+      longer loaded on subsequent restarts.
      </para>
     </step>

--
2.52.0