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 1wZNSu-000zWX-1F for pgsql-hackers@arkaria.postgresql.org; Tue, 16 Jun 2026 06:40:04 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wZNSt-00FnOj-0l for pgsql-hackers@arkaria.postgresql.org; Tue, 16 Jun 2026 06:40:03 +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 1wZNSs-00FnOa-30 for pgsql-hackers@lists.postgresql.org; Tue, 16 Jun 2026 06:40:02 +0000 Received: from mail-ot1-x331.google.com ([2607:f8b0:4864:20::331]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1wZNSq-00000000g1s-2q4q for pgsql-hackers@lists.postgresql.org; Tue, 16 Jun 2026 06:40:02 +0000 Received: by mail-ot1-x331.google.com with SMTP id 46e09a7af769-7e904193a5fso86217a34.0 for ; Mon, 15 Jun 2026 23:40:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1781591999; cv=none; d=google.com; s=arc-20240605; b=gNqHVIn4V4cqDgyWdVLnwTnygfUzLA1ilS5Jqs4hJ91stvrHqgixMsT0qVdRTJmPTR KcsI8jgoutRBYk9OItUlb0CZRGU4AaCvs0x0STcsUsyGtsn0QSpXW+x/bWzo5zu39ogz 5awOiEXYbSqJ3Alz45ATMnb22CEd7hGkzHtMYHOMis+v6Ac3vHPiNzwHrNKWr7XHSF9V xmrgOOIiwrRINqlV+/jJIfi+WZYs0P7Ade97+fVY+J5H8sQRf8PGwN/tRsBAPL0hQFTg 5rynVmLERwOAPKhyO9RRmbK2MX9ljbN9hkJl1RdfRkor9OkNJfjP8xYf55Vw2XjUUrmd swTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=iZ8NU4aipMi853ZrrRsUZxm9P2V+aW65DzDVX92m1k0=; fh=UAa9BjMxa8fig9afD4V1rBwxqcB8oSF9HxcRFqW4RNs=; b=Bdw07BtK0xdO2Sq9C34jo5o/rRIyIHRbHXcMAspG0Ceof/bbuRLK6hkl5Iq0JPx05A lAh/awhFdBupkhOB5849F6BnVR33vZE+xj8i0xWsTP/o2LGtG+WHHcVpxf0ijYjPX1H+ Pcd0sz2K8/Cihxx7nspG762CxdIA1uZnvlpFXgjaURhq20FMcjIj+rn8tup+yqzZjPfy FwqZU2+ozmAe9SMBLrquERmVZtcPAoEIj44EHK8r2YKp+kFJT/1RH/m5NACQszNY5Cli /K/txhN4vJB+oW7pu3emvZBzMZylHH1WNyWUzrtlhnajw7u1eEObGITVl0Uc73pXR3/S VtJA==; darn=lists.postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1781591999; x=1782196799; darn=lists.postgresql.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=iZ8NU4aipMi853ZrrRsUZxm9P2V+aW65DzDVX92m1k0=; b=faPWE6HzJpHI6GGPrbyMKEkPYkWawIfB+3IbAE1oGkatXRrPoPvd+oWxk1xYK0XRHF s3Mg25hypfwllPmrOj3VwBmaa6lNlgW38xS6+Xy2Euw98y1a7IylGpcFTejWUk1govay 3JVAfyfTz09q5Qk3Nclz4ezvOp14BIcZf4o9iFPPUl4I9OfVfFIgrrDXog7WqMioG2gO BHRPVNy7AfnFtqrIzHbJDYY63XRGgPnHQ18+KNj/fLzt5JjAlFAIotqE6VzXaGh9CGX5 f56H3Qs7kVas1qJpE4aJv6nLIJxZjE8T2bxEIBBTK+CEx9O6QtZcX36RG9Jv1Jm2B2fd WEFg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1781591999; x=1782196799; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=iZ8NU4aipMi853ZrrRsUZxm9P2V+aW65DzDVX92m1k0=; b=D/QtK87RdFa1D1NVMFI0BJgR0FmXnBK1RprN7H9pUg5m7ltOq2nepDfme4+dkzPn3l XxmHhz8Nw2onPx66+Rv017jdV1Nm19hFF6JGGFCMRng+btgPdv6B+SUu3MhTIbWQiKmx yXnFcmSZlss1VaQdcNSFnMILQd1z2NrbfAcfGGqNuWkP/uLbjjezpMLozPDHEL+0nYHN SbmpexZsbWLDqQAQdP5IKB+h22JnyHWv6erONgcwMebDrNkhGq/nImvSScGkBpBQJNPx 0kYt2R5cvyzVPnYyJqh3JyMWYETX77lv767NUPPq/UJ5GrgLzGVCTXnuQeldzunv8/oV UA0g== X-Forwarded-Encrypted: i=1; AFNElJ//rLGUQ4+JHAsKY8XGsXRokS3mRDELUmFhTGOm+OuNgj2ST38huVkwGfff6L+dPIUJVVLqMzCCCRWbn/iQ@lists.postgresql.org X-Gm-Message-State: AOJu0YyZFO/IkqJgaPYKT0kshC00RgxdMJzojMmukKaloPIEP+4VfVwF WYaoiWkm5CiSGcRtahclAd1/RuflQ349Z3kriGAzLnis+AEwVuaCVqhgfdh2T9oV48S0Dg61E1J oI20SmQVo+Cm4lj8DivE65bQ1UZEgAoA= X-Gm-Gg: Acq92OFSA4Rtge/AZQ67KCvllXUCI0qGud9dYwEtLsr35D6kxNjuoKNwsT4/OaMZQBx GYz1x+mO8+rYz2i3YOnH9XSTe5CepWeXPUS8P+9Qy3nBprDjzJMAtZehDN7/TWPR3RHSMFhC7WO v5QUstFJ6qQ8oNpGJlQnAealM1d9A8kr3JPl1/NHaFJrJmNlR04vL4bNWlWD9Vt9Qc9o1LAiQeU VoEXw0Jw0UrQIUZvh2xaGACb3XHqQkstjDLkGjf9FtburOEIZfMdPDWdSswUNjUfDLNMKgNTFa3 bC402/4= X-Received: by 2002:a05:6808:1209:b0:482:5bd1:d8e5 with SMTP id 5614622812f47-4880c3adf3amr1977190b6e.9.1781591998732; Mon, 15 Jun 2026 23:39:58 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Shlok Kyal Date: Tue, 16 Jun 2026 12:09:47 +0530 X-Gm-Features: AVVi8CeWJRQO7KbRnVBh23JrZB4xYhiWZ7amI8Vfs5q-NDSM-WTt7ZL9YpPiSdk Message-ID: Subject: Re: synchronized_standby_slots behavior inconsistent with quorum-based synchronous replication To: Ashutosh Sharma Cc: shveta malik , Amit Kapila , "Zhijie Hou (Fujitsu)" , Ajin Cherian , SATYANARAYANA NARLAPURAM , PostgreSQL-development , PostgreSQL Hackers Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Mon, 15 Jun 2026 at 16:09, Ashutosh Sharma wrote= : > > Hi Shlok, > > Thanks for reviewing the patch and sharing your feedback - all your > comments are well noted. Please find my responses below. > > On Fri, Jun 12, 2026 at 6:33=E2=80=AFPM Shlok Kyal wrote: > > > > Hi Ashutosh, > > > > I have reviewed the patches. Here are some comments: > > > > 1. Should we update the doc for function "pg_logical_slot_get_changes".= It says: > > ``` > > If the specified slot is a logical failover slot then the function will > > not return until all physical slots specified in > > synchronized_= standby_slots > > have confirmed WAL receipt. > > ``` > > This line "return until all physical slots specified in" seems wrong > > after introduction of "FIRST/ANY" > > > > Agreed, it indeed needs correction, it has been addressed in the attached= patch. > > > 2. Similarly, should we update the doc for function > > "pg_replication_slot_advance"? It also says: > > ``` > > If the specified slot is a > > logical failover slot then the function will not return until all > > physical slots specified in > > synchronized_= standby_slots > > have confirmed WAL receipt. > > ``` > > Same as comment 1, this has been corrected in the attached patch as well > > > > > 3. Comment in syncrep_gram.y states: > > * syncrep_gram.y - Parser for synchronous_standby_names > > > > Since synchronosed_standby_slots is reusing this, should we update this= comment? > > > > Agreed, update was due. This has been taken care of in the attached patch= . > > > 4. Similarly for syncrep_scanner.l, we have comment: > > * syncrep_scanner.l > > * a lexical scanner for synchronous_standby_names > > > > Should we update it? > > Agreed and updated in the attached patch. > > > > > 5. enum "SyncStandbySlotsState" and stuct "SyncStandbySlotsStateInfo" s= hould be > > mentioned in typedefs.list, so that pgindent works properly. > > > > These have been added to the typdefs.list > > PFA attached patches with all these changes. > Hi Ashutosh, I checked the CFbot and saw the test was failing [1]. It is failing for the test: not ok 4 - guc_privs 171 ms diff -U3 /__w/postgresql/postgresql/src/test/modules/unsafe_tests/expected/= guc_privs.out /__w/postgresql/postgresql/build/testrun/unsafe_tests/regress/results/guc_p= rivs.out --- /__w/postgresql/postgresql/src/test/modules/unsafe_tests/expected/guc_p= rivs.out 2026-06-15 11:08:26.979460240 +0000 +++ /__w/postgresql/postgresql/build/testrun/unsafe_tests/regress/results/g= uc_privs.out 2026-06-15 11:20:01.829423596 +0000 @@ -590,8 +590,7 @@ -- Cannot set synchronized_standby_slots to an invalid slot name ALTER SYSTEM SET synchronized_standby_slots=3D'invalid*'; ERROR: invalid value for parameter "synchronized_standby_slots": "invalid= *" -DETAIL: replication slot name "invalid*" contains invalid character -HINT: Replication slot names may only contain lower case letters, numbers, and the underscore character. +DETAIL: syntax error at or near "*" -- Can set synchronized_standby_slots to a non-existent slot name ALTER SYSTEM SET synchronized_standby_slots=3D'missing'; -- Reset the GUC In HEAD, validate_sync_standby_slots() called SplitIdentifierString() and then ReplicationSlotValidateNameInternal() for each element, which produced the slot-name-specific error for inputs such as 'invalid*'. With patch synchronized_standby_slots validation use the syncrep parser and a syntax error is reported instead. I think we should update the corresponding expected file. [1]: https://github.com/postgresql-cfbot/postgresql/actions/runs/2754199642= 6/job/81406065089 Thanks, Shlok Kyal