On Tue, Sep 19, 2023 at 07:14:49PM +0530, vignesh C wrote:
> Here is a patch to set max_logical_replication_workers as 0 while the
> server is started to prevent the launcher from being started. Since
> this configuration is present from v10, no need for any version check.
> I have done upgrade tests for v10-master, v11-master, ... v16-master
> and found it to be working fine.

The project policy is to support pg_upgrade for 10 years, and 9.6 was
released in 2016:
https://www.postgresql.org/docs/9.6/release-9-6.html

>      snprintf(cmd, sizeof(cmd),
> -             "\"%s/pg_ctl\" -w -l \"%s/%s\" -D \"%s\" -o \"-p %d -b%s %s%s\" 
> start",
> +             "\"%s/pg_ctl\" -w -l \"%s/%s\" -D \"%s\" -o \"-p %d -b%s 
> %s%s%s\" start",
>               cluster->bindir,
>               log_opts.logdir,
>               SERVER_LOG_FILE, cluster->pgconfig, cluster->port,
>               (cluster == &new_cluster) ?
>               " -c synchronous_commit=off -c fsync=off -c 
> full_page_writes=off" : "",
> +             " -c max_logical_replication_workers=0",
>               cluster->pgopts ? cluster->pgopts : "", socket_string);
>  
>      /*

And this code path is used to start postmaster instances for old and
new clusters.  So it seems to me that it is incorrect if this is not
conditional based on the cluster version.
--
Michael

Attachment: signature.asc
Description: PGP signature

Reply via email to