Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1vNNd8-0015Tv-0C for pgsql-hackers@arkaria.postgresql.org; Mon, 24 Nov 2025 03:52:46 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vNNd5-00GMzk-1I for pgsql-hackers@arkaria.postgresql.org; Mon, 24 Nov 2025 03:52:43 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1vNNd5-00GMzb-0K for pgsql-hackers@lists.postgresql.org; Mon, 24 Nov 2025 03:52:43 +0000 Received: from mail-pf1-x434.google.com ([2607:f8b0:4864:20::434]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1vNNd2-0019rZ-2B for pgsql-hackers@lists.postgresql.org; Mon, 24 Nov 2025 03:52:42 +0000 Received: by mail-pf1-x434.google.com with SMTP id d2e1a72fcca58-7aace33b75bso3551079b3a.1 for ; Sun, 23 Nov 2025 19:52:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1763956358; x=1764561158; darn=lists.postgresql.org; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=qyi9OfLTcTlRevo5a7h+4PgXBY72LmWxz+AOXHoSHC0=; b=SyhrZmW4lSPwR6UVbwS3pazMQX0lDlDPDTNUPS2ubU8r9mNuwebSP4L0ZRMuQCqXkJ /qV1RCpVB9Ijq2cdfuCbuVkNsaXc/O/P4KUBj1r44iNJA8kDMuhp5K+1bUdQIrMQW16X rVRv4pIfFDKlhVYPQmPMCP8AlG7TwwDidqt0vvxaeZ46ox3ynt3ZB0va+LnzfMBawmS8 kDlv2O1U1QZWSVIrbosPuZ9rhKrDSJuH09LY8lJqCI2glmkp9SzdOXHOaWORqUJUVFLC Hoem1HrMWiiq+nda89x5o6kgbMqlUuVcJPs0AfB+cbbXLksvcUBdtVXI7p6icUrC42ve 3Q+g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763956358; x=1764561158; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:x-gm-gg:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=qyi9OfLTcTlRevo5a7h+4PgXBY72LmWxz+AOXHoSHC0=; b=nrPdFYpwLW5LdAYShO5kxPiDV69ulo2vfNE6YFlwN8W1ZbJXJ5T0JS2LoqDZShT4go gkdkvpX7cw3mwg8OuGiuFQUwpWE+FddV5bVSAxYj2lbvd1pd7IfEuLqWQlUzRAqR/W6w 1dz4YEL9IFbBMJiMttAX8RJuVCXwvp/H6IRizHAC+p9b/uEf3taP+JJo0mwUJhoXDKke ddbp/vxlaqwmRvcH7CdY+3RBRGK7UqwlCUMG6wzhex9C0FHcoiJ3/T/3Qcku9O16hQO3 qGeE+VcXp+XW2iuFUL3DJptBA+u4zt5/fBiAMLu449qE0i0BvuUNEDBmqTXdB17IDUUx 6Dig== X-Gm-Message-State: AOJu0Yyl75faON98gpcdAnzXPQOG8RdWfY0Dmo4oe8R73zwG9oE85N3K D1fJNRjq3XnDLwpQ8HMIeDWdkMUmgoWZAFq3o2M6ejK5gEpdGPueAhDakOvmNjt/ysK4fQ== X-Gm-Gg: ASbGncusZJ5Y3M99SCmJQjVF9i7XoufrLDNT5GaR1Lg3LpqbMzwfa22VX8LFIjIP0VG YvIY6qPQIluEZ6uvXgjYuUoUKYa17UMSMlKfN5z3b+XXHXRZGtrJRr8feH4JuS0hlpSQoNj9tP3 LBrjHw6deqJ1hqbPRNKgPD3d3oSJWh4H2dpVQ4tr4zXkkfP1f2JJVfnLcgTQtQ4Ysmma68dkYCB ZaGyPvIjkEZek2pvZJ+p55b0GKnjGJkSIy0gsxWHfIJ5M4+dzEUv2aS/U4918tWRCPwwBtA/0zQ Z01qRFucZHqpbKQESV2olVuTeFrZc6VFlaiXLZeGAuGNTyzlQ36NtsEUNPF/IC/acSCzQyeFapw +qYxxUpwRVTwiZfQXRoqG+icVV0kOnOxMDLpV+iAiAQfhoL9xKRfSFtf+SX40QT1NI63EqNBP9c sRwFgF1sL2KdnGzoIAAgA= X-Google-Smtp-Source: AGHT+IGmX63VLi0zSOz+SA0hj8nVb+Are+UbF+JhfNrqvokB8CzHVEv62adkzeaCM0+TaaS1T76EhQ== X-Received: by 2002:a05:6a00:1896:b0:7a9:c21a:55b4 with SMTP id d2e1a72fcca58-7c58e50a5f9mr11198784b3a.28.1763956357944; Sun, 23 Nov 2025 19:52:37 -0800 (PST) Received: from smtpclient.apple ([45.32.121.103]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-7c3ecf7dc6asm13060811b3a.4.2025.11.23.19.52.36 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sun, 23 Nov 2025 19:52:37 -0800 (PST) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3826.700.81\)) Subject: Re: Allow GUC settings in CREATE SUBSCRIPTION CONNECTION to take effect From: Chao Li In-Reply-To: Date: Mon, 24 Nov 2025 11:51:58 +0800 Cc: PostgreSQL Hackers Content-Transfer-Encoding: quoted-printable Message-Id: <313C50E8-E05A-4A64-95FF-C9DC5A70ECD7@gmail.com> References: <6E35E0EF-A842-408A-A264-DB6D428C2BD6@gmail.com> <726A237D-D1C1-49E5-99A0-AC5899897DA6@gmail.com> To: Fujii Masao X-Mailer: Apple Mail (2.3826.700.81) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk > On Nov 22, 2025, at 22:14, Fujii Masao wrote: >=20 > On Sat, Nov 22, 2025 at 10:31=E2=80=AFAM Chao Li = wrote: >>=20 >>=20 >>=20 >>> On Nov 22, 2025, at 00:14, Fujii Masao = wrote: >>>=20 >>> On Fri, Nov 21, 2025 at 6:24=E2=80=AFPM Chao Li = wrote: >>>> No, what I was thinking is that, we could combine the three set = statement into one, like: >>>>=20 >>>> ``` >>>> Set a =3D 1; set b =3D 2; set c =3D 3; >>>> ``` >>>> So that sends a single statement to publisher server, that reduces = round-trip from 3 times to one time. >>>=20 >>> I see the point about combining the three SET commands to reduce = round trips, >>> but I think the current approach in the patch (i.e., issuing a = separate >>> SET command for each parameter) is sufficient. I still don't think >>> the additional round trip during replication connection startup is >>> a real concern. This approach is also consistent with what = postgres_fdw >>> and pg_dump already do. >>>=20 >>=20 >> No problem. I don=E2=80=99t have a strong option here. I just saw you = mentioned overhead of round trip and thought to improve. But I agree = that overhead is tiny, not a real concern. >=20 > Okay, thanks! >=20 > I've updated the patch to use lengthof() as you suggested. > The revised version is attached. >=20 > Regards, >=20 > --=20 > Fujii Masao > V3 looks good to me. >> now all user specified options expect the 3 will be kept, will that = expose a hold where user badly specifies some option that may break = logical replication? If that=E2=80=99s true, then we need to parse user = specified options and do some verifications. >>=20 >=20 > Yeah, I agree that if certain GUCs can break logical replication, > we should enforce "safe" values, just as we currently do for = datestyle. > And if any other GUCs can cause the issue, they could affect > postgres_fdw etc, so the fix would need to be broader. Just want to clarify if you mean you will handle this in a future patch? Best regards, -- Chao Li (Evan) HighGo Software Co., Ltd. https://www.highgo.com/