Re: Proposal: Support custom authentication methods using hooks

2022-03-02 Thread Jonathan S. Katz
On 3/2/22 3:24 AM, Peter Eisentraut wrote: On 01.03.22 22:17, Jonathan S. Katz wrote: If you're moving to a newer version of PostgreSQL, you likely have to update your connection drivers anyway (rebuilt against new libpq, supporting any changes in the protocol, etc). I would prefer more data

Re: Proposal: Support custom authentication methods using hooks

2022-03-02 Thread Stephen Frost
Greetings, * Peter Eisentraut (peter.eisentr...@enterprisedb.com) wrote: > On 01.03.22 22:34, Andres Freund wrote: > >The cases I've heard about are about centralizing auth across multiple cloud > >services. Including secret management in some form. E.g. allowing an > >application to auth to

Re: Proposal: Support custom authentication methods using hooks

2022-03-02 Thread Stephen Frost
Greetings, * Andres Freund (and...@anarazel.de) wrote: > On 2022-02-28 11:26:06 +0100, Peter Eisentraut wrote: > > We already have a variety of authentication mechanisms that support central > > management: LDAP, PAM, Kerberos, Radius. > > LDAP, PAM and Radius all require cleartext passwords, so

Re: Changing "Hot Standby" to "hot standby"

2022-03-02 Thread Aleksander Alekseev
Hi Daniel, > Here is a patch that changes "Hot Standby" to "hot standby" in high-availability.sgml, so we have a consistent wording. > Thoughts? ``` - Hot Standby Parameter Reference + hot standby Parameter Reference ``` Pretty sure that for titles we should keep English capitalization

Re: logical replication empty transactions

2022-03-02 Thread Ajin Cherian
On Wed, Mar 2, 2022 at 1:01 PM shiy.f...@fujitsu.com wrote: > > 4. > @@ -1617,9 +1829,21 @@ pgoutput_stream_prepare_txn(LogicalDecodingContext > *ctx, > ReorderBufferTXN *txn, >

Re: Add 64-bit XIDs into PostgreSQL 15

2022-03-02 Thread Aleksander Alekseev
Hi hackers, > In this part, I suppose you've found a definite bug. Thanks! There are a > couple > of ways how it could be fixed: > > 1. If we enforce checkpoint at replica promotion then we force full-page > writes after each page modification afterward. > > 2. Maybe it's worth using BufferDesc

Re: Add CHECKPOINT_REQUESTED flag to the log message in LogCheckpointStart()

2022-03-02 Thread Bharath Rupireddy
On Wed, Mar 2, 2022 at 5:41 PM Nitin Jadhav wrote: > > Hi, > > I have noticed that the CHECKPOINT_REQUESTED flag information is not > present in the log message of LogCheckpointStart() function. I would > like to understand if it was missed or left intentionally. The log > message describes all

Re: row filtering for logical replication

2022-03-02 Thread Euler Taveira
On Wed, Mar 2, 2022, at 8:45 AM, Tomas Vondra wrote: > While working on the column filtering patch, which touches about the > same places, I noticed two minor gaps in testing: > > 1) The regression tests do perform multiple ALTER PUBLICATION commands, > tweaking the row filter. But there are no

Re: Commitfest 2022-03 Patch Triage Part 1a.i

2022-03-02 Thread Daniel Gustafsson
> On 1 Mar 2022, at 17:16, Greg Stark wrote: > Last November Daniel Gustafsson did a patch triage. It took him three > emails to get through the patches in the commitfest back then. It should be noted that I only powered through the patches that had been in 3+ commitfests at the time.. >

Add CHECKPOINT_REQUESTED flag to the log message in LogCheckpointStart()

2022-03-02 Thread Nitin Jadhav
Hi, I have noticed that the CHECKPOINT_REQUESTED flag information is not present in the log message of LogCheckpointStart() function. I would like to understand if it was missed or left intentionally. The log message describes all the possible checkpoint flags except CHECKPOINT_REQUESTED flag. I

Re: row filtering for logical replication

2022-03-02 Thread Tomas Vondra
Hi, While working on the column filtering patch, which touches about the same places, I noticed two minor gaps in testing: 1) The regression tests do perform multiple ALTER PUBLICATION commands, tweaking the row filter. But there are no checks the row filter was actually modified / stored in the

Re: [HACKERS] WIP aPatch: Pgbench Serialization and deadlock errors

2022-03-02 Thread Fabien COELHO
Hello Tatsuo-san, It seems the patch is ready for committer except below. Do you guys want to do more on below? I'm planning a new review of this significant patch, possibly over the next week-end, or the next. -- Fabien.

Re: Report checkpoint progress with pg_stat_progress_checkpoint (was: Report checkpoint progress in server logs)

2022-03-02 Thread Nitin Jadhav
Thanks for reviewing. > > > I suggested upthread to store the starting timeline instead. This way > > > you can > > > deduce whether it's a restartpoint or a checkpoint, but you can also > > > deduce > > > other information, like what was the starting WAL. > > > > I don't understand why we

Re: [PATCH] Add reloption for views to enable RLS

2022-03-02 Thread Wolfgang Walther
Dean Rasheed: That is also the main reason I preferred naming it "security_invoker" - it is consistent with other databases and eases transition from such systems. [...] For my part, I find myself more and more convinced that "security_invoker" is the right name, because it matches the

Re: Design of pg_stat_subscription_workers vs pgstats

2022-03-02 Thread Amit Kapila
On Wed, Mar 2, 2022 at 1:26 PM Andres Freund wrote: > > > > While rebasing, I was wondering why pgstat_reset_subscription_counter() > > > has > > > "all subscription counters" support. We don't have a function to reset all > > > function stats or such either. > > > > > > > We have similar thing

Re: standby recovery fails (tablespace related) (tentative patch and discussion)

2022-03-02 Thread Kyotaro Horiguchi
At Wed, 02 Mar 2022 16:59:09 +0900 (JST), Kyotaro Horiguchi wrote in > At Thu, 20 Jan 2022 17:19:04 +0900 (JST), Kyotaro Horiguchi > wrote in > > At Thu, 20 Jan 2022 15:07:22 +0900 (JST), Kyotaro Horiguchi > > wrote in > > CI now likes this version for all platforms. > > An xlog.c

Re: Handle infinite recursion in logical replication setup

2022-03-02 Thread Amit Kapila
On Wed, Feb 23, 2022 at 11:59 AM vignesh C wrote: > ... ... > I have attached a basic patch for this, if the idea is accepted, I > will work further to test more scenarios, add documentation, and test > and post an updated patch. > For the second problem, Table synchronization of table including

Re: pg_stop_backup() v2 incorrectly marked as proretset

2022-03-02 Thread Aleksander Alekseev
Hi Michael, ``` Datum pg_stop_backup_v2(PG_FUNCTION_ARGS) { -ReturnSetInfo *rsinfo = (ReturnSetInfo *) fcinfo->resultinfo; +#define PG_STOP_BACKUP_V2_COLS 3 TupleDesctupdesc; -Tuplestorestate *tupstore; -MemoryContext per_query_ctx; -MemoryContext oldcontext; -

Re: psql: Make SSL info display more compact

2022-03-02 Thread Daniel Gustafsson
> On 1 Mar 2022, at 09:44, Peter Eisentraut > wrote: > I propose a reduced patch that just removes the "bits" display, since that is > redundant with the "cipher" No objections from me. -- Daniel Gustafsson https://vmware.com/

Changing "Hot Standby" to "hot standby"

2022-03-02 Thread Daniel Westermann (DWE)
Hi, with reference to the discussion in docs: https://www.postgresql.org/message-id/flat/2221339.1645896597%40sss.pgh.pa.us#5a346c15ec2edbe8fcc93a1ffc2a7c7d Here is a patch that changes "Hot Standby" to "hot standby" in high-availability.sgml, so we have a consistent wording. Thoughts? There

Re: [PATCH] Add reloption for views to enable RLS

2022-03-02 Thread Dean Rasheed
On Tue, 1 Mar 2022 at 16:40, Christoph Heiss wrote: > > That is also the main reason I preferred naming it "security_invoker" - > it is consistent with other databases and eases transition from such > systems. > > I kept "check_permissions_owner" for now. Constantly changing it around > with each

Re: pg_stop_backup() v2 incorrectly marked as proretset

2022-03-02 Thread Michael Paquier
On Wed, Mar 02, 2022 at 05:22:35PM +0900, Kyotaro Horiguchi wrote: > But the patch forgets to remove an useless variable. Indeed. I forgot to look at stderr. >> /* Initialise attributes information in the tuple descriptor */ >> tupdesc =

Re: create_index test fails when synchronous_commit = off @ master

2022-03-02 Thread Aleksander Alekseev
Hi hackers, > I don't see what else can be done either. Here is the corresponding patch. Here is an updated patch that includes the commit message. -- Best regards, Aleksander Alekseev v2-0001-Use-synchronous_commit-on-in-test_setup.sql.patch Description: Binary data

Re: PG DOCS - logical replication filtering

2022-03-02 Thread Aleksander Alekseev
Hi hackers, > I see that a large part of the documentation is commented and marked as > TBA (Column Filters, Combining Different Kinds of Filters). Could you > please clarify if it's a work-in-progress patch? If it's not, I believe the > commented part should be removed before committing. > > > >

Re: Add id's to various elements in protocol.sgml

2022-03-02 Thread Peter Eisentraut
On 01.03.22 18:27, Brar Piening wrote: Also I'm not sure how well the autogenerated ids are reproducible over time/versions/builds, and if it is wise to use them as targets to link to from somewhere else. Autogenerated ids are stable across builds of the same source. They would change if the

RE: Optionally automatically disable logical replication subscriptions on error

2022-03-02 Thread osumi.takami...@fujitsu.com
On Wednesday, March 2, 2022 12:47 PM Masahiko Sawada wrote: > After more thoughts, should we do both AbortOutOfAnyTransaction() and error > message handling while holding interrupts? That is, > > HOLD_INTERRUPTS(); > EmitErrorReport(); > FlushErrorState(); > AbortOutOfAny Transaction(); >

Re: Add id's to various elements in protocol.sgml

2022-03-02 Thread Peter Eisentraut
On 01.03.22 20:50, Brar Piening wrote: Patch is attached. I don't think it should get applied this way, though. The fact that you only get links for section headers that have manually assigned ids would be pretty surprising for users of the docs and in some files (e.g. protocol-flow.html) only

Re: PG DOCS - logical replication filtering

2022-03-02 Thread Amit Kapila
On Wed, Mar 2, 2022 at 2:37 PM Aleksander Alekseev wrote: > > > I see that a large part of the documentation is commented and marked as TBA > (Column Filters, Combining Different Kinds of Filters). Could you please > clarify if it's a work-in-progress patch? If it's not, I believe the >

Re: PG DOCS - logical replication filtering

2022-03-02 Thread Aleksander Alekseev
Hi again, > The second sentence seems to be redundant. Actually, I'm wrong on this one. > -- Best regards, Aleksander Alekseev

Re: PG DOCS - logical replication filtering

2022-03-02 Thread Aleksander Alekseev
Hi Peter, > PSA a PG docs patch that is associated with the logical replication > Row Filters feature which was recently pushed [1]. The patch looks mostly OK, but I have several nitpicks. ``` By default, all data from all published tables will be replicated to the appropriate

Re: [HACKERS] WIP aPatch: Pgbench Serialization and deadlock errors

2022-03-02 Thread Tatsuo Ishii
Hi Yugo and Fabien, It seems the patch is ready for committer except below. Do you guys want to do more on below? >> # TESTS >> >> I suggested to simplify the tests by using conditionals & sequences. You >> reported that you got stuck. Hmmm. >> >> I tried again my tests which worked fine when

Re: more descriptive message for process termination due to max_slot_wal_keep_size

2022-03-02 Thread Kyotaro Horiguchi
At Wed, 02 Mar 2022 15:37:19 +0900 (JST), Kyotaro Horiguchi wrote in > The CI was confused by the mixed patches for multiple PG versions. In > this version the patchset for master are attached as .patch and that > for PG13 as .txt. Yeah It is of course the relevant check should be fixed.

Re: Two noncritical bugs of pg_waldump

2022-03-02 Thread Kyotaro Horiguchi
At Fri, 25 Feb 2022 10:48:47 -0800, Andres Freund wrote in > Hi, > > On 2022-02-14 18:18:47 +0900, Kyotaro Horiguchi wrote: > > > If I give an empty file to the tool it complains as the follows. > > > > > > > pg_waldump: fatal: could not read file "hoge": No such file or directory > > > > > >

Re: Proposal: Support custom authentication methods using hooks

2022-03-02 Thread Peter Eisentraut
On 01.03.22 22:34, Andres Freund wrote: The cases I've heard about are about centralizing auth across multiple cloud services. Including secret management in some form. E.g. allowing an application to auth to postgres, redis and having the secret provided by infrastructure, rather than having to

RE: Failed transaction statistics to measure the logical replication progress

2022-03-02 Thread shiy.f...@fujitsu.com
Hi, A comments on the v26 patch. The following document about pg_stat_subscription_stats view only says that "showing statistics about errors", should we add something about transactions here? pg_stat_subscription_statspg_stat_subscription_stats One row per subscription,

Re: Proposal: Support custom authentication methods using hooks

2022-03-02 Thread Peter Eisentraut
On 01.03.22 22:17, Jonathan S. Katz wrote: If you're moving to a newer version of PostgreSQL, you likely have to update your connection drivers anyway (rebuilt against new libpq, supporting any changes in the protocol, etc). I would prefer more data to support that argument, but this is

Re: pg_stop_backup() v2 incorrectly marked as proretset

2022-03-02 Thread Kyotaro Horiguchi
At Wed, 2 Mar 2022 16:46:01 +0900, Michael Paquier wrote in > Hi all, > > In my hunt looking for incorrect SRFs, I have noticed a new case of a > system function marked as proretset while it builds and returns only > one record. And this is a popular one: pg_stop_backup(), labelled > v2. > >

Re: [PATCH] Expose port->authn_id to extensions and triggers

2022-03-02 Thread Peter Eisentraut
On 01.03.22 23:05, Jacob Champion wrote: On Tue, 2022-03-01 at 19:56 +0100, Peter Eisentraut wrote: This patch contains no documentation. I'm having a hard time understanding what the name "session_authn_id" is supposed to convey. The comment for the Port.authn_id field says this is the

Re: Add the replication origin name and commit-LSN to logical replication worker errcontext

2022-03-02 Thread Masahiko Sawada
On Wed, Mar 2, 2022 at 4:07 PM Kyotaro Horiguchi wrote: > > At Wed, 2 Mar 2022 14:39:54 +0900, Masahiko Sawada > wrote in > > On Wed, Mar 2, 2022 at 11:55 AM Amit Kapila wrote: > > > > > > On Mon, Feb 28, 2022 at 5:46 PM Masahiko Sawada > > > wrote: > > > > > > > > I've attached two patches:

Re: Rewriting the test of pg_upgrade as a TAP test - take three - remastered set

2022-03-02 Thread Michael Paquier
On Wed, Mar 02, 2022 at 12:01:17AM -0800, Andres Freund wrote: > But in a bad way, because EXTRA_REGRESS_OPTS now always wins, even for stuff > we want to override. Note how test.sh explicitly specifies port, bindir etc > after the pre-existing EXTRA_REGRESS_OPTS. Ah, right. Will fix. -- Michael

Re: Rewriting the test of pg_upgrade as a TAP test - take three - remastered set

2022-03-02 Thread Andres Freund
Hi, On 2022-03-02 15:57:23 +0900, Michael Paquier wrote: > Do others have an opinion about a backpatch of the bugfix? Nobody has > complained about that since pg_upgrade exists, so I have just done the > change on HEAD. WFM. > +++ b/src/bin/pg_upgrade/t/001_basic.pl > @@ -0,0 +1,9 @@ > +use

Re: Rewriting the test of pg_upgrade as a TAP test - take three - remastered set

2022-03-02 Thread Andres Freund
On 2022-02-15 13:02:41 +0900, Michael Paquier wrote: > >> + @regress_command = (@regress_command, @extra_opts); > >> + > >> + $oldnode->command_ok(@regress_command, > >> + 'regression test run on old instance'); > > > > I also think this should take EXTRA_REGRESS_OPTS into account -

<    1   2