Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ozlAU-0003Vm-AG for pgsql-hackers@arkaria.postgresql.org; Mon, 28 Nov 2022 20:55:58 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1ozlAT-0007tu-6I for pgsql-hackers@arkaria.postgresql.org; Mon, 28 Nov 2022 20:55:57 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ozl9k-0002Eb-Br for pgsql-hackers@lists.postgresql.org; Mon, 28 Nov 2022 20:55:12 +0000 Received: from momjian.us ([72.94.173.45]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ozl9h-0000eg-Rj for pgsql-hackers@lists.postgresql.org; Mon, 28 Nov 2022 20:55:11 +0000 Received: from bruce by momjian.us with local (Exim 4.94.2) (envelope-from ) id 1ozl9f-00G4DB-6d; Mon, 28 Nov 2022 15:55:07 -0500 Date: Mon, 28 Nov 2022 15:55:07 -0500 From: Bruce Momjian To: Andrey Borodin Cc: Bharath Rupireddy , Kyotaro Horiguchi , Laurenz Albe , PostgreSQL Hackers , SATYANARAYANA NARLAPURAM Subject: Re: An attempt to avoid locally-committed-but-not-replicated-to-standby-transactions in synchronous replication Message-ID: References: <9290b55b6ae2b04e002ca9dadadd1cca09461482.camel@cybertec.at> <20220805.114916.994654810780821553.horikyota.ntt@gmail.com> <20220809.161236.1486509314201074910.horikyota.ntt@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Sun, Nov 27, 2022 at 11:26:50AM -0800, Andrey Borodin wrote: > Some funny stuff. If a user tries to cancel a non-replicated transaction > Azure Postgres will answer: "user requested cancel while waiting for > synchronous replication ack. The COMMIT record has already flushed to > WAL locally and might not have been replicatead to the standby. We > must wait here." > AWS RDS will answer: "ignoring request to cancel wait for synchronous > replication" > Yandex Managed Postgres will answer: "canceling wait for synchronous > replication due requested, but cancelation is not allowed. The > transaction has already committed locally and might not have been > replicated to the standby. We must wait here." > > So, for many services providing Postgres as a service it's only a > matter of wording. Wow, you are telling me all three cloud vendors changed how query cancel behaves on an unresponsive synchronous replica? That is certainly a testament that the community needs to change or at least review our behavior. -- Bruce Momjian https://momjian.us EDB https://enterprisedb.com Embrace your flaws. They make you human, rather than perfect, which you will never be.