Re: pg_dump, pg_dumpall, pg_restore: Add --no-policies option - Mailing list pgsql-hackers

From Tom Lane
Subject Re: pg_dump, pg_dumpall, pg_restore: Add --no-policies option
Date
Msg-id 3869229.1742163983@sss.pgh.pa.us
Whole thread Raw
In response to Re: pg_dump, pg_dumpall, pg_restore: Add --no-policies option  (Greg Sabino Mullane <htamfids@gmail.com>)
List pgsql-hackers
Greg Sabino Mullane <htamfids@gmail.com> writes:
> Re-reviewed this patch: still compiles, tests pass, and does what it says
> on the tin. +1

Pushed with minor corrections:

* The patch still hadn't absorbed jian he's point that pg_dump main()
needs to fill ropt->no_policies from dopt.no_policies.  It's possible
that that had no externally-visible effect, but just as a matter of
style we should fill the RestoreOptions fully.

* It seems better to me to implement the no_policies filter in
getPolicies() not dumpPolicy().  That way we don't waste effort
on retrieving catalog data we aren't going to use.  It might be
problematic if we had to deal with dependency chains involving
policies, but AFAIK there is nothing that depends on a policy.

* I fixed a couple bits of sloppy alphabetization and updated
the Perl style in the test script.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Robert Treat
Date:
Subject: Re: Disabling vacuum truncate for autovacuum
Next
From: Peter Smith
Date:
Subject: Re: TOAST versus toast