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.94.2) (envelope-from ) id 1s8442-009Ocp-Hk for pgsql-hackers@arkaria.postgresql.org; Fri, 17 May 2024 20:20:28 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1s8442-00HXHN-HI for pgsql-hackers@arkaria.postgresql.org; Fri, 17 May 2024 20:20:26 +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.94.2) (envelope-from ) id 1s8442-00HXHF-2n for pgsql-hackers@lists.postgresql.org; Fri, 17 May 2024 20:20:26 +0000 Received: from mail-pl1-x62d.google.com ([2607:f8b0:4864:20::62d]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1s843y-000laG-K5 for pgsql-hackers@postgresql.org; Fri, 17 May 2024 20:20:25 +0000 Received: by mail-pl1-x62d.google.com with SMTP id d9443c01a7336-1e83a2a4f2cso18073865ad.1 for ; Fri, 17 May 2024 13:20:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=j-davis-com.20230601.gappssmtp.com; s=20230601; t=1715977221; x=1716582021; darn=postgresql.org; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:from:to:cc:subject :date:message-id:reply-to; bh=lgXm5IwNT6ytfJfRF9t/lwX9rmQM5fN9x/tChZYiVpg=; b=uoE7tIyO/IAaUiKVtPKk2mNRybswv6VVd2G+KageDLd8e1ZLCZb7HjqYrf8+oiGwzK s/7CV2D4SSwHX1unKl8lR/FpT4oxaRJKpkwt1mvBiUTBfXbOVaA5HwMEnskFT/YyhudB wa16Vtj6kMdsd75aeqr6qZ3ZqjNz+fq5FAneNcb7SO/amdsXcx7rXiFJT+dWmNY40p9f uFn6LLUTH/dmqtF8LhtmkPAktEJB2xx+BGi3xdqvMGqq4JGTfXCU927WFr4GGpsTp0pO ICfHjJkNvZIJDyy8WBABpvVXKAhCKlShJ86g/EBKGcJKtLBzr2cKdgp8eu92ImnCHkrP a4FQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715977221; x=1716582021; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=lgXm5IwNT6ytfJfRF9t/lwX9rmQM5fN9x/tChZYiVpg=; b=OAwqdPQXk8O37XJA1EhZl/xF3CV+5AU+dVXTg5pmnSL5DkBYnJid4FSdaPtYfFFZuU sQTDjVNkNUdIVLWtES3+WSeFaO0nFMgPrUl86H3NWJ40nxdPdwaGyrAtweYzR/a6tbiI smQ4kRtFloJx5JEQWTuVCjbg/W3swh+naRm6IONWDubI8+BpnAku0ApkKRqijEEPoj/7 tl4Auq0BX3mllJNbomkNSs5xyavnbXxbjxbfvc2U2JTDk1w7qUhimzc6SA+OXREKbbt2 ITHqyhH4y+Q5hDLoCGxldBoxtpDtdQTuMlVZKWNpSZnkPIXSD74Tj16pcPLF8KeKVK3/ vl0w== X-Forwarded-Encrypted: i=1; AJvYcCU40sa+rT2+sfaLdqMUETjH1JKQRZATLQXt+5paZMf1uhKZQBdXmocjHnOozxlKi1TVx34sLd8SS2pan1547sGGjZEBbNZcDeuizBJn X-Gm-Message-State: AOJu0Yw+nbkIjDBZ52yrcX4nE6IWQ3uGI7IxbjiH0K9gtNPKLxFFDDHp DRNUo4Q8+BrSF3xh7YQf+O3jiiZmNWjnpEh/mE8YL6fJgKmIFo0DoPaeTebaRg== X-Google-Smtp-Source: AGHT+IH2aPvnsygIfHPz0P9ZcF7qrr95vi30pMF+6cneB+sZPtsFLg56evoWGjCGXiuhPM/T6LsBeQ== X-Received: by 2002:a05:6a00:3c91:b0:6f4:74b5:f536 with SMTP id d2e1a72fcca58-6f4e03e7fabmr26566735b3a.34.1715977221225; Fri, 17 May 2024 13:20:21 -0700 (PDT) Received: from jeff-laptop.lan (c-76-102-242-158.hsd1.ca.comcast.net. [76.102.242.158]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-6f4d2ade2besm15574458b3a.98.2024.05.17.13.20.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 May 2024 13:20:20 -0700 (PDT) Message-ID: <1e2256b744836aeb485c61954e9d8272f80141a0.camel@j-davis.com> Subject: Re: Comments on Custom RMGRs From: Jeff Davis To: Robert Haas Cc: Danil Anisimow , Andres Freund , PostgreSQL Hackers Date: Fri, 17 May 2024 13:20:19 -0700 In-Reply-To: References: <20220512034010.4oqa76pasrulkw32@alap3.anarazel.de> <20220512234207.pwwp6q33f72byet2@alap3.anarazel.de> <0892cd00635c8bcd458de6d43d31cf61953da1b2.camel@j-davis.com> <727b0f3b48aec2a4f968bf11c6fa8ca6382b6cca.camel@j-davis.com> <22e756affaad88b77a52d67cb532ed2a544f2e36.camel@j-davis.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.44.4-0ubuntu2 MIME-Version: 1.0 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Fri, 2024-05-17 at 14:56 -0400, Robert Haas wrote: > (2) a detailed > description of how a non-core table AM or index AM is expected to be > able to make use of this. Bonus points if the person providing that > rationale can say credibly that they've actually implemented this and > it works great with 100TB of production data. That's a chicken-and-egg problem and we should be careful about setting the bar too high for table AM improvements. Ultimately, AM authors will benefit more from a steady stream of improvements that sometimes miss the mark than complete stagnation, as long as we use reasonable judgement. There aren't a lot of table AMs, and to create a good one you need a lot of internals knowledge. If it's an important AM, the developers are surely going to try it out on mainline occasionally, and expect API breaks. If the API breaks for them in some fundamental way, they can complain and we still have time to fix it. > The problem here is not only that we don't want to commit a hook that > does nothing useful. We also don't want to commit a hook that works > wonderfully for someone but we have no idea why. If we do that, then > we don't know whether it's OK to modify the hook in the future as the > code evolves, or more to the point, which kinds of modifications will > be acceptable. We have to have some kind of understanding between us and AM authors that they need to participate in discussions when using these APIs, try changes during development, be adaptable when they change from release to release, and come back and tell us when something is wrong. > And also, the next person who wants to use it is likely > to have to figure out all on their own how to do so, instead of being > able to refer to comments or documentation or the commit message or > at > least a mailing list post. Obviously it would be better to have a nice example table AM in /contrib, different enough from heap, but nobody has done that yet. You could argue that we never should have exposed the API without something like this in the first place, but that's also a big ask and we'd probably still not have it. Regarding this particular change: the checkpointing hook seems more like a table AM feature, so I agree with you that we should have a good idea how a real table AM might use this, rather than only pg_stat_statements. Regards, Jeff Davis