Re: Multiple pg_waldump --rmgr options - Mailing list pgsql-hackers

From Daniel Gustafsson
Subject Re: Multiple pg_waldump --rmgr options
Date
Msg-id D94C9152-1362-4637-A529-109EE92D4E74@yesql.se
Whole thread Raw
In response to Multiple pg_waldump --rmgr options  (Heikki Linnakangas <hlinnaka@iki.fi>)
Responses Re: Multiple pg_waldump --rmgr options
List pgsql-hackers
> On 18 May 2021, at 15:50, Heikki Linnakangas <hlinnaka@iki.fi> wrote:

> The reason is that if you specify multiple --rmgr options, only the last one takes effect.

That's in line with how options are handled for most binaries, so this will go
against that.  That being said, I don't think thats a problem here really given
what this tool is and it's intended usecase.

This patch makes the special case "--rmgr=list" a bit more awkward than before
IMO, as it breaks the list processing, but nothing we can't live with.

> I propose the attached to allow selecting multiple rmgrs

I agree with the other +1's in this thread, and am marking this as ready for
committer.

As a tiny nitpick for readability, I would move this line inside the string
comparison case where the rmgr is selected.  Not that it makes any difference
in practice, but since that's where the filtering is set it seems a hair
tidier.
+      config.filter_by_rmgr_enabled = true;

--
Daniel Gustafsson        https://vmware.com/




pgsql-hackers by date:

Previous
From: Arne Roland
Date:
Subject: Re: Rename of triggers for partitioned tables
Next
From: Ranier Vilela
Date:
Subject: Re: Fix uninitialized copy_data var (src/backend/commands/subscriptioncmds.c)