Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TwJ48-0000kG-Vr for pgsql-hackers@arkaria.postgresql.org; Fri, 18 Jan 2013 21:01:33 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.72) (envelope-from ) id 1TwJ47-0001hn-Uf for pgsql-hackers@arkaria.postgresql.org; Fri, 18 Jan 2013 21:01:31 +0000 Received: from magus.postgresql.org ([87.238.57.229]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TwJ46-0001hf-D5 for pgsql-hackers@postgresql.org; Fri, 18 Jan 2013 21:01:30 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TwJ44-0000OS-9q for pgsql-hackers@postgresql.org; Fri, 18 Jan 2013 21:01:30 +0000 Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.5/8.14.5) with ESMTP id r0IL1I4X000694; Fri, 18 Jan 2013 16:01:18 -0500 (EST) From: Tom Lane To: Andres Freund cc: Alvaro Herrera , Erik Rijkers , Kevin Grittner , pgsql-hackers@postgresql.org Subject: Re: foreign key locks In-reply-to: <20130118204643.GA4359@awork2.anarazel.de> References: <20121129152326.69330@gmx.com> <20121129160220.GA4942@alvh.no-ip.org> <20121129161654.GB4942@alvh.no-ip.org> <20121228204847.GD4150@alvh.no-ip.org> <20130110210040.GB4110@alvh.no-ip.org> <20130118200204.GH4063@alvh.no-ip.org> <28623.1358541467@sss.pgh.pa.us> <20130118204643.GA4359@awork2.anarazel.de> Comments: In-reply-to Andres Freund message dated "Fri, 18 Jan 2013 21:46:43 +0100" Date: Fri, 18 Jan 2013 16:01:18 -0500 Message-ID: <693.1358542878@sss.pgh.pa.us> X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org Andres Freund writes: > On 2013-01-18 15:37:47 -0500, Tom Lane wrote: >> I doubt it ever came up before. What use is logging only the content of >> a buffer page? Surely you'd need to know, for example, which relation >> and page number it is from. > It only got to be a length of 0 because the the data got removed due to > a logged full page write. And the backup block contains the data about > which blocks it is logging in itself. And if the full-page-image case *hadn't* been invoked, what then? I still don't see a very good argument for xlog records with no fixed data. > I wonder if the check shouldn't just check write_len instead, directly > below the loop that ads backup blocks. We're not changing this unless you can convince me that the read-side error check mentioned in the comment is useless. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers