[COMMITTERS] pgsql: Improve ALTER TABLE documentation
Improve ALTER TABLE documentation The ALTER TABLE documentation wasn't terribly clear when it came to which commands could be combined together and what it meant when they were. In particular, SET TABLESPACE *can* be combined with other commands, when it's operating against a single table, but not when multiple tables are being moved with ALL IN TABLESPACE. Further, the actions are applied together but not really in 'parallel', at least today. Pointed out by: Amit Langote Improved wording from Tom. Back-patch to 9.4, where the ALL IN TABLESPACE option was added. Discussion: https://www.postgresql.org/message-id/14c535b4-13ef-0590-1b98-76af355a0763%40lab.ntt.co.jp Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/ec2bc3264ef007e6d7b6463029de689273161336 Modified Files -- doc/src/sgml/ref/alter_table.sgml | 8 1 file changed, 4 insertions(+), 4 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Improve ALTER TABLE documentation
Improve ALTER TABLE documentation The ALTER TABLE documentation wasn't terribly clear when it came to which commands could be combined together and what it meant when they were. In particular, SET TABLESPACE *can* be combined with other commands, when it's operating against a single table, but not when multiple tables are being moved with ALL IN TABLESPACE. Further, the actions are applied together but not really in 'parallel', at least today. Pointed out by: Amit Langote Improved wording from Tom. Back-patch to 9.4, where the ALL IN TABLESPACE option was added. Discussion: https://www.postgresql.org/message-id/14c535b4-13ef-0590-1b98-76af355a0763%40lab.ntt.co.jp Branch -- REL9_4_STABLE Details --- http://git.postgresql.org/pg/commitdiff/b5fe1d4cd93d281eef7ab6718716d169609b000a Modified Files -- doc/src/sgml/ref/alter_table.sgml | 8 1 file changed, 4 insertions(+), 4 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Improve ALTER TABLE documentation
Improve ALTER TABLE documentation The ALTER TABLE documentation wasn't terribly clear when it came to which commands could be combined together and what it meant when they were. In particular, SET TABLESPACE *can* be combined with other commands, when it's operating against a single table, but not when multiple tables are being moved with ALL IN TABLESPACE. Further, the actions are applied together but not really in 'parallel', at least today. Pointed out by: Amit Langote Improved wording from Tom. Back-patch to 9.4, where the ALL IN TABLESPACE option was added. Discussion: https://www.postgresql.org/message-id/14c535b4-13ef-0590-1b98-76af355a0763%40lab.ntt.co.jp Branch -- REL9_6_STABLE Details --- http://git.postgresql.org/pg/commitdiff/eaac6c75858b693ef5e8968b509114c30896ba19 Modified Files -- doc/src/sgml/ref/alter_table.sgml | 8 1 file changed, 4 insertions(+), 4 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: For 8.0 servers, get last built-in oid from pg_database
For 8.0 servers, get last built-in oid from pg_database We didn't start ensuring that all built-in objects had OIDs less than 16384 until 8.1, so for 8.0 servers we still need to query the value out of pg_database. We need this, in particular, to distinguish which casts were built-in and which were user-defined. For HEAD, we only worry about going back to 8.0, for the back-branches, we also ensure that 7.0-7.4 work. Discussion: https://www.postgresql.org/message-id/flat/20160504183952.GE10850%40tamriel.snowman.net Branch -- REL9_4_STABLE Details --- http://git.postgresql.org/pg/commitdiff/107943f1a9b2823e5faef78f3ca1400a7612a24e Modified Files -- src/bin/pg_dump/pg_dump.c | 36 +++- 1 file changed, 23 insertions(+), 13 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Fix dumping of casts and transforms using built-in functions
Fix dumping of casts and transforms using built-in functions In pg_dump.c dumpCast() and dumpTransform(), we would happily ignore the cast or transform if it happened to use a built-in function because we weren't including the information about built-in functions when querying pg_proc from getFuncs(). Modify the query in getFuncs() to also gather information about functions which are used by user-defined casts and transforms (where "user-defined" means "has an OID >= FirstNormalObjectId"). This also adds to the TAP regression tests for 9.6 and master to cover these types of objects. Back-patch all the way for casts, back to 9.5 for transforms. Discussion: https://www.postgresql.org/message-id/flat/20160504183952.GE10850%40tamriel.snowman.net Branch -- REL9_2_STABLE Details --- http://git.postgresql.org/pg/commitdiff/da57166b7dceae917a73f414d9d13e07d4354066 Modified Files -- src/bin/pg_dump/pg_dump.c | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: For 8.0 servers, get last built-in oid from pg_database
For 8.0 servers, get last built-in oid from pg_database We didn't start ensuring that all built-in objects had OIDs less than 16384 until 8.1, so for 8.0 servers we still need to query the value out of pg_database. We need this, in particular, to distinguish which casts were built-in and which were user-defined. For HEAD, we only worry about going back to 8.0, for the back-branches, we also ensure that 7.0-7.4 work. Discussion: https://www.postgresql.org/message-id/flat/20160504183952.GE10850%40tamriel.snowman.net Branch -- REL9_6_STABLE Details --- http://git.postgresql.org/pg/commitdiff/e45319bb7796e3ab8095da329a1f73d22aaa57c4 Modified Files -- src/bin/pg_dump/pg_dump.c | 38 -- 1 file changed, 24 insertions(+), 14 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: For 8.0 servers, get last built-in oid from pg_database
For 8.0 servers, get last built-in oid from pg_database We didn't start ensuring that all built-in objects had OIDs less than 16384 until 8.1, so for 8.0 servers we still need to query the value out of pg_database. We need this, in particular, to distinguish which casts were built-in and which were user-defined. For HEAD, we only worry about going back to 8.0, for the back-branches, we also ensure that 7.0-7.4 work. Discussion: https://www.postgresql.org/message-id/flat/20160504183952.GE10850%40tamriel.snowman.net Branch -- REL9_2_STABLE Details --- http://git.postgresql.org/pg/commitdiff/59a3898914d73fdf7bcac895098e7a164b64f4fe Modified Files -- src/bin/pg_dump/pg_dump.c | 36 +++- 1 file changed, 23 insertions(+), 13 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: For 8.0 servers, get last built-in oid from pg_database
For 8.0 servers, get last built-in oid from pg_database We didn't start ensuring that all built-in objects had OIDs less than 16384 until 8.1, so for 8.0 servers we still need to query the value out of pg_database. We need this, in particular, to distinguish which casts were built-in and which were user-defined. For HEAD, we only worry about going back to 8.0, for the back-branches, we also ensure that 7.0-7.4 work. Discussion: https://www.postgresql.org/message-id/flat/20160504183952.GE10850%40tamriel.snowman.net Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/19990918d3fa2a445561627ed415b5891602f7fe Modified Files -- src/bin/pg_dump/pg_dump.c | 60 ++- 1 file changed, 54 insertions(+), 6 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Fix dumping of casts and transforms using built-in functions
Fix dumping of casts and transforms using built-in functions In pg_dump.c dumpCast() and dumpTransform(), we would happily ignore the cast or transform if it happened to use a built-in function because we weren't including the information about built-in functions when querying pg_proc from getFuncs(). Modify the query in getFuncs() to also gather information about functions which are used by user-defined casts and transforms (where "user-defined" means "has an OID >= FirstNormalObjectId"). This also adds to the TAP regression tests for 9.6 and master to cover these types of objects. Back-patch all the way for casts, back to 9.5 for transforms. Discussion: https://www.postgresql.org/message-id/flat/20160504183952.GE10850%40tamriel.snowman.net Branch -- REL9_6_STABLE Details --- http://git.postgresql.org/pg/commitdiff/542975a147525caa659ac08220b81c32a60f0a5c Modified Files -- src/bin/pg_dump/pg_dump.c| 46 +- src/bin/pg_dump/t/002_pg_dump.pl | 82 +--- 2 files changed, 88 insertions(+), 40 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Fix dumping of casts and transforms using built-in functions
Fix dumping of casts and transforms using built-in functions In pg_dump.c dumpCast() and dumpTransform(), we would happily ignore the cast or transform if it happened to use a built-in function because we weren't including the information about built-in functions when querying pg_proc from getFuncs(). Modify the query in getFuncs() to also gather information about functions which are used by user-defined casts and transforms (where "user-defined" means "has an OID >= FirstNormalObjectId"). This also adds to the TAP regression tests for 9.6 and master to cover these types of objects. Back-patch all the way for casts, back to 9.5 for transforms. Discussion: https://www.postgresql.org/message-id/flat/20160504183952.GE10850%40tamriel.snowman.net Branch -- REL9_4_STABLE Details --- http://git.postgresql.org/pg/commitdiff/13f51dacfab83f868df09370d10d4d9932fc0a61 Modified Files -- src/bin/pg_dump/pg_dump.c | 15 +++ 1 file changed, 11 insertions(+), 4 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: For 8.0 servers, get last built-in oid from pg_database
For 8.0 servers, get last built-in oid from pg_database We didn't start ensuring that all built-in objects had OIDs less than 16384 until 8.1, so for 8.0 servers we still need to query the value out of pg_database. We need this, in particular, to distinguish which casts were built-in and which were user-defined. For HEAD, we only worry about going back to 8.0, for the back-branches, we also ensure that 7.0-7.4 work. Discussion: https://www.postgresql.org/message-id/flat/20160504183952.GE10850%40tamriel.snowman.net Branch -- REL9_3_STABLE Details --- http://git.postgresql.org/pg/commitdiff/fc03f7dd195fba5ff3abd222d7e7d4a8e3a63341 Modified Files -- src/bin/pg_dump/pg_dump.c | 36 +++- 1 file changed, 23 insertions(+), 13 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Fix dumping of casts and transforms using built-in functions
Fix dumping of casts and transforms using built-in functions In pg_dump.c dumpCast() and dumpTransform(), we would happily ignore the cast or transform if it happened to use a built-in function because we weren't including the information about built-in functions when querying pg_proc from getFuncs(). Modify the query in getFuncs() to also gather information about functions which are used by user-defined casts and transforms (where "user-defined" means "has an OID >= FirstNormalObjectId"). This also adds to the TAP regression tests for 9.6 and master to cover these types of objects. Back-patch all the way for casts, back to 9.5 for transforms. Discussion: https://www.postgresql.org/message-id/flat/20160504183952.GE10850%40tamriel.snowman.net Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/2259bf672cb45b4104dcb835354beeb1c6105b0e Modified Files -- src/bin/pg_dump/pg_dump.c| 46 +- src/bin/pg_dump/t/002_pg_dump.pl | 85 +--- 2 files changed, 90 insertions(+), 41 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Fix dumping of casts and transforms using built-in functions
Fix dumping of casts and transforms using built-in functions In pg_dump.c dumpCast() and dumpTransform(), we would happily ignore the cast or transform if it happened to use a built-in function because we weren't including the information about built-in functions when querying pg_proc from getFuncs(). Modify the query in getFuncs() to also gather information about functions which are used by user-defined casts and transforms (where "user-defined" means "has an OID >= FirstNormalObjectId"). This also adds to the TAP regression tests for 9.6 and master to cover these types of objects. Back-patch all the way for casts, back to 9.5 for transforms. Discussion: https://www.postgresql.org/message-id/flat/20160504183952.GE10850%40tamriel.snowman.net Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/1efc5dba05a81bd91a0d3659f4a4ccfb4c36e680 Modified Files -- src/bin/pg_dump/pg_dump.c | 30 -- 1 file changed, 24 insertions(+), 6 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: For 8.0 servers, get last built-in oid from pg_database
For 8.0 servers, get last built-in oid from pg_database We didn't start ensuring that all built-in objects had OIDs less than 16384 until 8.1, so for 8.0 servers we still need to query the value out of pg_database. We need this, in particular, to distinguish which casts were built-in and which were user-defined. For HEAD, we only worry about going back to 8.0, for the back-branches, we also ensure that 7.0-7.4 work. Discussion: https://www.postgresql.org/message-id/flat/20160504183952.GE10850%40tamriel.snowman.net Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/94476436a627d80319d49afe5724633b781e735a Modified Files -- src/bin/pg_dump/pg_dump.c | 36 +++- 1 file changed, 23 insertions(+), 13 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Fix dumping of casts and transforms using built-in functions
Fix dumping of casts and transforms using built-in functions In pg_dump.c dumpCast() and dumpTransform(), we would happily ignore the cast or transform if it happened to use a built-in function because we weren't including the information about built-in functions when querying pg_proc from getFuncs(). Modify the query in getFuncs() to also gather information about functions which are used by user-defined casts and transforms (where "user-defined" means "has an OID >= FirstNormalObjectId"). This also adds to the TAP regression tests for 9.6 and master to cover these types of objects. Back-patch all the way for casts, back to 9.5 for transforms. Discussion: https://www.postgresql.org/message-id/flat/20160504183952.GE10850%40tamriel.snowman.net Branch -- REL9_3_STABLE Details --- http://git.postgresql.org/pg/commitdiff/1f2cfd26f50d3a7d885961aa68361d40d7753949 Modified Files -- src/bin/pg_dump/pg_dump.c | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Silence compiler warnings
Silence compiler warnings Rearrange a bit of code to ensure that 'mode' in LWLockRelease is obviously always set, which seems a bit cleaner and avoids a compiler warning (thanks to Robert for the suggestion!). In GetCachedPlan(), initialize 'plan' to silence a compiler warning, but also add an Assert() to make sure we don't ever actually fall through with 'plan' still being set to NULL, since we are about to dereference it. Neither of these appear to be live bugs but at least gcc 5.4.0-6ubuntu1~16.04.4 doesn't quite have the smarts to realize that. Discussion: https://www.postgresql.org/message-id/20161129152102.GR13284%40tamriel.snowman.net Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/d97b14ddab2059e1d73c0cd17f26bac4ef13e682 Modified Files -- src/backend/storage/lmgr/lwlock.c | 9 - src/backend/utils/cache/plancache.c | 4 +++- 2 files changed, 7 insertions(+), 6 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
Re: [COMMITTERS] pgsql: Add support for restrictive RLS policies
Andres, * Andres Freund (and...@anarazel.de) wrote: > On 2016-12-05 20:51:02 +0000, Stephen Frost wrote: > > Add support for restrictive RLS policies > This is missing a catversion bump. Ewps, apologies and thanks for pointing it out. Fixed. Stephen signature.asc Description: Digital signature
[COMMITTERS] pgsql: Bump catversion for restrictive RLS changes
Bump catversion for restrictive RLS changes Mea culpa. Pointed out by Andres. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/cb9dcbc1eebd8cccf98d7236b2c9bb82caf8b45d Modified Files -- src/include/catalog/catversion.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Add support for restrictive RLS policies
Add support for restrictive RLS policies We have had support for restrictive RLS policies since 9.5, but they were only available through extensions which use the appropriate hooks. This adds support into the grammer, catalog, psql and pg_dump for restrictive RLS policies, thus reducing the cases where an extension is necessary. In passing, also move away from using "AND"d and "OR"d in comments. As pointed out by Alvaro, it's not really appropriate to attempt to make verbs out of "AND" and "OR", so reword those comments which attempted to. Reviewed By: Jeevan Chalke, Dean Rasheed Discussion: https://postgr.es/m/20160901063404.gy4...@tamriel.snowman.net Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/093129c9d9fc231649b3cc27b8086443ccbbbc22 Modified Files -- doc/src/sgml/catalogs.sgml| 13 ++ doc/src/sgml/ddl.sgml | 58 +- doc/src/sgml/ref/alter_policy.sgml| 7 +- doc/src/sgml/ref/create_policy.sgml | 38 src/backend/catalog/system_views.sql | 6 + src/backend/commands/policy.c | 9 + src/backend/nodes/copyfuncs.c | 1 + src/backend/nodes/equalfuncs.c| 1 + src/backend/parser/gram.y | 43 +++-- src/backend/rewrite/rowsecurity.c | 54 +++--- src/bin/pg_dump/pg_dump.c | 69 +--- src/bin/pg_dump/pg_dump.h | 3 +- src/bin/pg_dump/t/002_pg_dump.pl | 33 +++- src/bin/psql/describe.c | 100 --- src/bin/psql/tab-complete.c | 29 ++- src/include/catalog/pg_policy.h | 16 +- src/include/nodes/parsenodes.h| 1 + src/include/rewrite/rowsecurity.h | 1 + src/test/regress/expected/rowsecurity.out | 284 -- src/test/regress/expected/rules.out | 4 + src/test/regress/sql/rowsecurity.sql | 45 - 21 files changed, 665 insertions(+), 150 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Add --no-blobs option to pg_dump
Add --no-blobs option to pg_dump Add an option to exclude blobs when running pg_dump. By default, blobs are included but this option can be used to exclude them while keeping the rest of the dump. Commment updates and regression tests from me. Author: Guillaume Lelarge Reviewed-by: Amul Sul Discussion: https://postgr.es/m/VisenaEmail.48.49926ea6f91dceb6.15355a48249@tc7-visena Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/4fafa579b0ab411f4cd2f30c57205d9b0ac27340 Modified Files -- doc/src/sgml/ref/pg_dump.sgml| 16 src/bin/pg_dump/pg_backup.h | 1 + src/bin/pg_dump/pg_dump.c| 19 +++-- src/bin/pg_dump/t/002_pg_dump.pl | 86 +++- 4 files changed, 117 insertions(+), 5 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Clarify pg_dump -b documentation
Clarify pg_dump -b documentation The documentation around the -b/--blobs option to pg_dump seemed to imply that it might be possible to add blobs to a "schema-only" dump or similar. Clarify that blobs are data and therefore will only be included in dumps where data is being included, even when -b is used to request blobs be included. The -b option has been around since before 9.2, so back-patch to all supported branches. Discussion: https://postgr.es/m/20161119173316.ga13...@tamriel.snowman.net Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/b57c8333b55e315927ca65016f1dbc165ef30df9 Modified Files -- doc/src/sgml/ref/pg_dump.sgml | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Clarify pg_dump -b documentation
Clarify pg_dump -b documentation The documentation around the -b/--blobs option to pg_dump seemed to imply that it might be possible to add blobs to a "schema-only" dump or similar. Clarify that blobs are data and therefore will only be included in dumps where data is being included, even when -b is used to request blobs be included. The -b option has been around since before 9.2, so back-patch to all supported branches. Discussion: https://postgr.es/m/20161119173316.ga13...@tamriel.snowman.net Branch -- REL9_4_STABLE Details --- http://git.postgresql.org/pg/commitdiff/be0b98fc21648f8483d00670a73c5e6ea89a5fb1 Modified Files -- doc/src/sgml/ref/pg_dump.sgml | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Clarify pg_dump -b documentation
Clarify pg_dump -b documentation The documentation around the -b/--blobs option to pg_dump seemed to imply that it might be possible to add blobs to a "schema-only" dump or similar. Clarify that blobs are data and therefore will only be included in dumps where data is being included, even when -b is used to request blobs be included. The -b option has been around since before 9.2, so back-patch to all supported branches. Discussion: https://postgr.es/m/20161119173316.ga13...@tamriel.snowman.net Branch -- REL9_6_STABLE Details --- http://git.postgresql.org/pg/commitdiff/d722927e1f0ce13a289c3dd8106265d27ca25c3b Modified Files -- doc/src/sgml/ref/pg_dump.sgml | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Clarify pg_dump -b documentation
Clarify pg_dump -b documentation The documentation around the -b/--blobs option to pg_dump seemed to imply that it might be possible to add blobs to a "schema-only" dump or similar. Clarify that blobs are data and therefore will only be included in dumps where data is being included, even when -b is used to request blobs be included. The -b option has been around since before 9.2, so back-patch to all supported branches. Discussion: https://postgr.es/m/20161119173316.ga13...@tamriel.snowman.net Branch -- REL9_3_STABLE Details --- http://git.postgresql.org/pg/commitdiff/eacdd5d7b06576c025f449b5a9eca0c11c85a5a2 Modified Files -- doc/src/sgml/ref/pg_dump.sgml | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Clarify pg_dump -b documentation
Clarify pg_dump -b documentation The documentation around the -b/--blobs option to pg_dump seemed to imply that it might be possible to add blobs to a "schema-only" dump or similar. Clarify that blobs are data and therefore will only be included in dumps where data is being included, even when -b is used to request blobs be included. The -b option has been around since before 9.2, so back-patch to all supported branches. Discussion: https://postgr.es/m/20161119173316.ga13...@tamriel.snowman.net Branch -- REL9_2_STABLE Details --- http://git.postgresql.org/pg/commitdiff/f45719997d3c8c8feb563ea9976ced15681de1ce Modified Files -- doc/src/sgml/ref/pg_dump.sgml | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Clarify pg_dump -b documentation
Clarify pg_dump -b documentation The documentation around the -b/--blobs option to pg_dump seemed to imply that it might be possible to add blobs to a "schema-only" dump or similar. Clarify that blobs are data and therefore will only be included in dumps where data is being included, even when -b is used to request blobs be included. The -b option has been around since before 9.2, so back-patch to all supported branches. Discussion: https://postgr.es/m/20161119173316.ga13...@tamriel.snowman.net Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/6c1a257fc67957410e421b0a276f845d9e1f9ff0 Modified Files -- doc/src/sgml/ref/pg_dump.sgml | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Correct psql documentation example
Correct psql documentation example An example in the psql documentation had an incorrect field name from what the command actually produced. Pointed out by Fabien COELHO Back-patch to 9.6 where the example was added. Discussion: https://postgr.es/m/alpine.DEB.2.20.1611291349400.19314@lancre Branch -- REL9_6_STABLE Details --- http://git.postgresql.org/pg/commitdiff/40eb468a1b2678475b648617bf5fc428739eb807 Modified Files -- doc/src/sgml/ref/psql-ref.sgml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Correct psql documentation example
Correct psql documentation example An example in the psql documentation had an incorrect field name from what the command actually produced. Pointed out by Fabien COELHO Back-patch to 9.6 where the example was added. Discussion: https://postgr.es/m/alpine.DEB.2.20.1611291349400.19314@lancre Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/489a51af12de58e336c7b97e793aed6d11bb13b5 Modified Files -- doc/src/sgml/ref/psql-ref.sgml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Clean up pg_dump tests, re-enable BLOB testing
Clean up pg_dump tests, re-enable BLOB testing Add a loop to check that each test covers all of the pg_dump runs. We (I) had been a bit sloppy when adding new runs and not making sure to mark if they should be under like or unlike for each test, this loop makes sure that the test system will complain if any are forgotten in the future. The loop also correctly handles the 'catch all' cases, which are used to avoid running unnecessary specific checks when a single catch-all can be done (eg: a no-acl run should not have any GRANT commands). Also, re-enable the testing of blobs, but use lo_from_bytea() instead of trying to be cute and writing out to a file and then reading it back in with psql, which proved to be difficult for some buildfarm members. This allows us to add support for testing the --no-blobs option which will be getting added shortly, provided the buildfarm doesn't blow up on this. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/8f91f323b4feef0371cd3db51be3007e44abd5e8 Modified Files -- src/bin/pg_dump/t/002_pg_dump.pl | 860 +++ 1 file changed, 695 insertions(+), 165 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Fix RLS with COPY (col1, col2) FROM tab
Fix RLS with COPY (col1, col2) FROM tab Attempting to COPY a subset of columns from a table with RLS enabled would fail due to an invalid query being constructed (using a single ColumnRef with the list of fields to exact in 'fields', but that's for the different levels of an indirection for a single column, not for specifying multiple columns). Correct by building a ColumnRef and then RestTarget for each column being requested and then adding those to the targetList for the select query. Include regression tests to hopefully catch if this is broken again in the future. Patch-By: Adam Brightwell Reviewed-By: Michael Paquier Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/814b9e9b8edf36cac65e0d8fcef17e50a04b1617 Modified Files -- src/backend/commands/copy.c | 63 -- src/test/regress/expected/copy2.out | 78 + src/test/regress/sql/copy2.sql | 63 ++ 3 files changed, 192 insertions(+), 12 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Fix RLS with COPY (col1, col2) FROM tab
Fix RLS with COPY (col1, col2) FROM tab Attempting to COPY a subset of columns from a table with RLS enabled would fail due to an invalid query being constructed (using a single ColumnRef with the list of fields to exact in 'fields', but that's for the different levels of an indirection for a single column, not for specifying multiple columns). Correct by building a ColumnRef and then RestTarget for each column being requested and then adding those to the targetList for the select query. Include regression tests to hopefully catch if this is broken again in the future. Patch-By: Adam Brightwell Reviewed-By: Michael Paquier Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/647a86e374d2eb01d8cdda2fc759a770b38cc232 Modified Files -- src/backend/commands/copy.c | 63 -- src/test/regress/expected/copy2.out | 78 + src/test/regress/sql/copy2.sql | 63 ++ 3 files changed, 192 insertions(+), 12 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Fix RLS with COPY (col1, col2) FROM tab
Fix RLS with COPY (col1, col2) FROM tab Attempting to COPY a subset of columns from a table with RLS enabled would fail due to an invalid query being constructed (using a single ColumnRef with the list of fields to exact in 'fields', but that's for the different levels of an indirection for a single column, not for specifying multiple columns). Correct by building a ColumnRef and then RestTarget for each column being requested and then adding those to the targetList for the select query. Include regression tests to hopefully catch if this is broken again in the future. Patch-By: Adam Brightwell Reviewed-By: Michael Paquier Branch -- REL9_6_STABLE Details --- http://git.postgresql.org/pg/commitdiff/190765a059cc5e8226cdb18b9715741b32b12255 Modified Files -- src/backend/commands/copy.c | 63 -- src/test/regress/expected/copy2.out | 78 + src/test/regress/sql/copy2.sql | 63 ++ 3 files changed, 192 insertions(+), 12 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
Re: [COMMITTERS] pgsql: Separate enum from struct
Peter, * Peter Eisentraut (pete...@gmx.net) wrote: > Separate enum from struct > > Otherwise the enum symbols are not visible outside the struct in C++. > > Reviewed-by: Thomas Munro Looks like this upset the buildfarm pretty badly... Thanks! Stephen signature.asc Description: Digital signature
[COMMITTERS] pgsql: Remove superuser checks in pgstattuple
Remove superuser checks in pgstattuple Now that we track initial privileges on extension objects and changes to those permissions, we can drop the superuser() checks from the various functions which are part of the pgstattuple extension and rely on the GRANT system to control access to those functions. Since a pg_upgrade will preserve the version of the extension which existed prior to the upgrade, we can't simply modify the existing functions but instead need to create new functions which remove the checks and update the SQL-level functions to use the new functions (and to REVOKE EXECUTE rights on those functions from PUBLIC). Thanks to Tom and Andres for adding support for extensions to follow update paths (see: 40b449a), allowing this patch to be much smaller since no new base version script needed to be included. Approach suggested by Noah. Reviewed by Michael Paquier. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/fd321a1dfd64d30bf1652ea6b39b654304f68ae4 Modified Files -- contrib/pgstattuple/Makefile | 7 +- contrib/pgstattuple/pgstatapprox.c| 39 ++-- contrib/pgstattuple/pgstatindex.c | 122 -- contrib/pgstattuple/pgstattuple--1.4--1.5.sql | 111 +++ contrib/pgstattuple/pgstattuple.c | 41 + contrib/pgstattuple/pgstattuple.control | 2 +- doc/src/sgml/pgstattuple.sgml | 8 ++ 7 files changed, 315 insertions(+), 15 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Correctly handle owned sequences with extensions
Correctly handle owned sequences with extensions With the refactoring of pg_dump to handle components, getOwnedSeqs needs to be a bit more intelligent regarding which components to dump when. Specifically, we can't simply use the owning table's components as the set of components to dump as the table might only be including certain components while all components of the sequence should be dumped, for example, when the table is a member of an extension while the sequence is not. Handle this by combining the set of components to be dumped for the sequence explicitly and those to be dumped for the table when setting the components to be dumped for the sequence. Also add a number of regression tests around this to, hopefully, catch any future changes which break the expected behavior. Discovered by: Philippe BEAUDOIN Reviewed by: Michael Paquier Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/f9e439b1ca81e3305b677d93c67299549625370c Modified Files -- src/bin/pg_dump/pg_dump.c | 27 ++-- src/bin/pg_dump/t/002_pg_dump.pl | 50 + src/test/modules/test_pg_dump/t/001_base.pl| 81 +- .../modules/test_pg_dump/test_pg_dump--1.0.sql | 6 +- 4 files changed, 155 insertions(+), 9 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Correctly dump database and tablespace ACLs
Correctly dump database and tablespace ACLs Dump out the appropriate GRANT/REVOKE commands for databases and tablespaces from pg_dumpall to replicate what the current state is. This was broken during the changes to buildACLCommands for 9.6+ servers for pg_init_privs. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/47f5bb9f539a7fff089724b1cbacc31613031895 Modified Files -- src/bin/initdb/initdb.c | 27 +-- src/bin/pg_dump/pg_dumpall.c | 95 +++- src/bin/pg_dump/t/002_pg_dump.pl | 153 +++ 3 files changed, 231 insertions(+), 44 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Add missing hyphen
Add missing hyphen Pointed out by Alexander Law Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/42ec6c2da699e8e0b1774988fa97297a2cdf716c Modified Files -- doc/src/sgml/runtime.sgml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Typo fix, buils -> builds
Typo fix, buils -> builds Pointed out by Alexander Law. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/e8bde9e2538a25b4a5deea569c4c48244c1a7e40 Modified Files -- doc/src/sgml/install-windows.sgml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Minor typos / copy-editing for snapmgr.c
Minor typos / copy-editing for snapmgr.c Noticed while reviewing snapshot management. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/40fc4575205dc563b88da1db9a8a75cc4d3b848a Modified Files -- src/backend/utils/time/snapmgr.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: pg_dump only selected components of ACCESS METHODs
pg_dump only selected components of ACCESS METHODs dumpAccessMethod() didn't get the memo that we now have a bitfield for the components which should be dumped instead of a simple boolean. Correct that by checking if the relevant bit is set for each component being dumped out (and not dumping it out if it isn't set). This corrects an issue where CREATE ACCESS METHOD commands were being included in non-binary-upgrades when an extension included an access method (as the bloom extensions does). Also add a regression test to make sure that we only dump out the ACCESS METHOD commands, when they are part of an extension, when doing a binary upgrade. Pointed out by Thom Brown. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/562f06f3f0da92e397a2f05e1b9b5bfbde336fb2 Modified Files -- src/bin/pg_dump/pg_dump.c | 26 -- src/test/modules/test_pg_dump/t/001_base.pl| 20 + .../modules/test_pg_dump/test_pg_dump--1.0.sql | 2 ++ 3 files changed, 36 insertions(+), 12 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Do not DROP default roles in pg_dumpall -c
Do not DROP default roles in pg_dumpall -c When pulling the list of roles to drop, exclude roles whose names begin with "pg_" (as we do when we are dumping the roles out to recreate them). Also add regression tests to cover pg_dumpall -c and this specific issue. Noticed by Rushabh Lathia. Patch by me. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/018eb027f181234be7a580e9502c40ac5ad04f77 Modified Files -- src/bin/pg_dump/pg_dumpall.c | 8 +++- src/bin/pg_dump/t/002_pg_dump.pl | 87 +++- 2 files changed, 93 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Qualify table usage in dumpTable() and use regclass
Qualify table usage in dumpTable() and use regclass All of the other tables used in the query in dumpTable(), which is collecting column-level ACLs, are qualified, so we should be qualifying the pg_init_privs, the related sub-select against pg_class and the other queries added by the pg_dump catalog ACLs work. Also, use ::regclass (or ::pg_catalog.regclass, where appropriate) instead of using a poorly constructed query to get the OID for various catalog tables. Issues identified by Noah and Alvaro, patch by me. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/2e8b4bf80473d0e4a4254b417424e79195a9ce6a Modified Files -- src/bin/pg_dump/dumputils.c | 24 +-- src/bin/pg_dump/pg_dump.c | 67 +++-- src/test/modules/test_pg_dump/t/001_base.pl | 8 ++-- 3 files changed, 50 insertions(+), 49 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Wording quibbles regarding initdb username
Wording quibbles regarding initdb username Use disallowed instead of reserved, cannot instead of can not, and double quotes instead of single quotes. Also add a test to cover the bug which started this discussion. Per discussion with Tom. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/6f69b96390eddf9c6129840eac511fd4159f01bb Modified Files -- src/bin/initdb/initdb.c| 2 +- src/bin/initdb/t/001_initdb.pl | 6 +- 2 files changed, 6 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Disallow superuser names starting with 'pg_' in initdb
Disallow superuser names starting with 'pg_' in initdb As with CREATE ROLE, disallow users from specifying initial superuser names which begin with 'pg_' in initdb. Per discussion with Tom. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/7df974ee0bfd8978830b941e7af5697fd4268656 Modified Files -- src/bin/initdb/initdb.c | 6 ++ 1 file changed, 6 insertions(+) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Disable BLOB test in pg_dump TAP tests
Disable BLOB test in pg_dump TAP tests Buildfarm member jacana appears to have an issue with running this test. It's not entirely clear to me why, but rather than try to fight with it, just disable it for now. None of the other tests try to write out from psql directly as this test does, so it seems likely that the rest of the tests will be fine (as they have been on numerous other systems). Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/0f97c722bb201c67312eec0a9ff3691cda37878f Modified Files -- src/bin/pg_dump/t/002_pg_dump.pl | 68 1 file changed, 34 insertions(+), 34 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Add test_pg_dump to @contrib_excludes
Add test_pg_dump to @contrib_excludes The test_pg_dump extension doesn't have a C component, so we need to exclude it from the MSVC build system trying to figure out how to build it. Also add a "MODULES" line to the Makefile, as test_extensions has. Might not be necessary, but seems good to keep things consistent. Lastly, remove the 'installcheck' line from test_pg_dump, as that was causing redefinition errors, at least on my box. This also makes test_pg_dump consistent with how commit_ts is set up. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/6e243c43c9b2d35f91a73d3982db6a0cad0eb64b Modified Files -- src/test/modules/test_pg_dump/Makefile | 4 +--- src/tools/msvc/Mkvcbuild.pm| 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
Re: [COMMITTERS] pgsql: Add TAP tests for pg_dump
* Alvaro Herrera (alvhe...@2ndquadrant.com) wrote: > Stephen Frost wrote: > > * Stephen Frost (sfr...@snowman.net) wrote: > > > > The intagg contrib modules doesn't have a .c file either, nor a > > > MODULES_big line, and I don't see any errors with it. I'm not terribly > > > familiar with how the Windows builds are run though. > > > > It looks like there's an exclude list that intagg is on for the MSVC > > build animals, presumably because it doesn't have a .c file to be > > compiled. > > > > I'm guessing the right answer here is to just add test_pg_dump to that > > list. > > I don't like this solution, because it means pg_dump will get little > testing on Windows. I agree with reverting now and figuring out a way > to enable this test on Windows after the beta. I suggest you grab hold > of your own Windows installation so that you can whack it locally until > it works, rather than waiting for buildfarm cycles. This is only for the test_pg_dump extension, which is specifically just testing pg_dump with extensions. The vast majority of the pg_dump tests are in src/bin/pg_dump and should be getting run on the Windows systems (once this issue is addressed). Thanks! Stephen signature.asc Description: Digital signature
[COMMITTERS] pgsql: Correct query in pg_dumpall:dumpRoles
Correct query in pg_dumpall:dumpRoles We need to use a new branch due to the 9.5 addition of bypassrls when adding in the clause to exclude pg_* roles from being dumped by pg_dumpall. Pointed out by Noah, patch by me. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/c778e27e13e883fb759f6100727aba80102933bd Modified Files -- src/bin/pg_dump/pg_dumpall.c | 10 ++ 1 file changed, 10 insertions(+) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
Re: [COMMITTERS] pgsql: Add TAP tests for pg_dump
* Tom Lane (t...@sss.pgh.pa.us) wrote: > Stephen Frost writes: > > * Stephen Frost (sfr...@snowman.net) wrote: > >> Looks like the test_pg_dump extension made the Windows builds upset. > >> I'm guessing that's because I set 'MODULES_big' even though there isn't > >> a .c component. > >> > >> Doing a local build with that commented out, assuming that works and > >> doesn't generate the .so any more on my Linux box, I'll push the change > >> up to hopefully fix those buildfarm members. > > > Alright, apparently that made other Windows buildfarm members unhappy... > > > I guess the next approach will be to add back MODULES_big and add in a > > .c file for the Windows systems to be happy about. I'm certainly open > > to other suggestions. > > You should not need to do that; cf src/test/modules/test_extensions, > which has got SQL-only extensions. test_extensions is also included in the "contrib_excludes" list in src/tools/msvc/Mkvcbuild.pm that I mentioned in my last email, so I'm thinking that's what is needed. > But at this point I think Peter's complaint has some force to it, and that > what you ought to do is revert the testing patch. You can have another go > after beta1. Are you suggesting commiting to still-9.6-HEAD post-beta1? I took Peter's comment as suggesting that adding the tests would have to wait til after we branched 9.6, as we do for features. I'd really like to have these tests included as that will make them available to others more easily to add on to, and I'm certainly planning to continue adding tests until I get pg_dump.c's coverage a lot better. That seems like the perfect kind of effort that should be happening right now- adding more tests and working to make sure that what's been committed is correct (and fixing it when it isn't, as discovered by the test suite with transforms and casts...). Thanks! Stephen signature.asc Description: Digital signature
Re: [COMMITTERS] pgsql: Add TAP tests for pg_dump
* Stephen Frost (sfr...@snowman.net) wrote: > Alright, apparently that made other Windows buildfarm members unhappy... > > I guess the next approach will be to add back MODULES_big and add in a > .c file for the Windows systems to be happy about. I'm certainly open > to other suggestions. > > The intagg contrib modules doesn't have a .c file either, nor a > MODULES_big line, and I don't see any errors with it. I'm not terribly > familiar with how the Windows builds are run though. It looks like there's an exclude list that intagg is on for the MSVC build animals, presumably because it doesn't have a .c file to be compiled. I'm guessing the right answer here is to just add test_pg_dump to that list. If there aren't any other suggestions, I'll go ahead and do that. Thanks! Stephen signature.asc Description: Digital signature
Re: [COMMITTERS] pgsql: Add TAP tests for pg_dump
* Stephen Frost (sfr...@snowman.net) wrote: > * Stephen Frost (sfr...@snowman.net) wrote: > > src/test/modules/test_pg_dump/Makefile | 25 + > > src/test/modules/test_pg_dump/README |2 + > > .../modules/test_pg_dump/expected/test_pg_dump.out |6 + > > src/test/modules/test_pg_dump/sql/test_pg_dump.sql |1 + > > src/test/modules/test_pg_dump/t/001_base.pl| 535 > > .../modules/test_pg_dump/test_pg_dump--1.0.sql | 15 + > > src/test/modules/test_pg_dump/test_pg_dump.control |3 + > > Looks like the test_pg_dump extension made the Windows builds upset. > I'm guessing that's because I set 'MODULES_big' even though there isn't > a .c component. > > Doing a local build with that commented out, assuming that works and > doesn't generate the .so any more on my Linux box, I'll push the change > up to hopefully fix those buildfarm members. Alright, apparently that made other Windows buildfarm members unhappy... I guess the next approach will be to add back MODULES_big and add in a .c file for the Windows systems to be happy about. I'm certainly open to other suggestions. The intagg contrib modules doesn't have a .c file either, nor a MODULES_big line, and I don't see any errors with it. I'm not terribly familiar with how the Windows builds are run though. Thanks! Stephen signature.asc Description: Digital signature
[COMMITTERS] pgsql: Remove MODULES_big from test_pg_dump
Remove MODULES_big from test_pg_dump The Makefile for test_pg_dump shouldn't have a MODULES_big line because there's no actual compiled bit for that extension. Hopefully this will fix the Windows buildfarm members which were complaining. In passing, also add the 'prove_installcheck' bit to the pg_dump and test_pg_dump Makefiles, to get the buildfarm members to actually run those tests. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/eccfeeb631fa44850b644661d8b2ce94d9ef4fc1 Modified Files -- src/bin/pg_dump/Makefile | 3 +++ src/test/modules/test_pg_dump/Makefile | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
Re: [COMMITTERS] pgsql: Add TAP tests for pg_dump
* Peter Eisentraut (peter.eisentr...@2ndquadrant.com) wrote: > On 5/6/16 2:06 PM, Stephen Frost wrote: > >Add TAP tests for pg_dump > > I'd be the first to welcome this, but what happened to feature freeze? These are just new tests..? I assumed that would be welcome during post feature-freeze, and certainly no one raised any concerns about adding these tests during the discussion prior to my commiting them. We back-patch new tests from time to time too, when they're associated with bug fixes, so I'm pretty confused why TAP tests would be an issue to add on HEAD post feature-freeze. If the consensus is that we shouldn't add new tests during feature freeze, I'll revert the patch that added them and add them later, but, for my 2c at least, I think we should be happy to add these even after feature freeze. Thanks! Stephen signature.asc Description: Digital signature
Re: [COMMITTERS] pgsql: Add TAP tests for pg_dump
* Stephen Frost (sfr...@snowman.net) wrote: > src/test/modules/test_pg_dump/Makefile | 25 + > src/test/modules/test_pg_dump/README |2 + > .../modules/test_pg_dump/expected/test_pg_dump.out |6 + > src/test/modules/test_pg_dump/sql/test_pg_dump.sql |1 + > src/test/modules/test_pg_dump/t/001_base.pl| 535 > .../modules/test_pg_dump/test_pg_dump--1.0.sql | 15 + > src/test/modules/test_pg_dump/test_pg_dump.control |3 + Looks like the test_pg_dump extension made the Windows builds upset. I'm guessing that's because I set 'MODULES_big' even though there isn't a .c component. Doing a local build with that commented out, assuming that works and doesn't generate the .so any more on my Linux box, I'll push the change up to hopefully fix those buildfarm members. Thanks! Stephen signature.asc Description: Digital signature
[COMMITTERS] pgsql: Correct pg_dump WHERE clause for functions/aggregates
Correct pg_dump WHERE clause for functions/aggregates The query to grab the function/aggregate information is now joining to pg_init_privs, so we can simplify (and correct) the WHERE clause used to determine if a given function's ACL has changed from the initial ACL on the function. Bug found by Noah, patch by me. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/64d60c8bf0703011d79dcb8a55dc42dcedc1e10f Modified Files -- src/bin/pg_dump/pg_dump.c | 12 ++-- 1 file changed, 2 insertions(+), 10 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Add TAP tests for pg_dump
Add TAP tests for pg_dump This TAP test suite will create a new cluster, populate it based on the 'create_sql' values in the '%tests' hash, run all of the runs defined in the '%pgdump_runs' hash, and then for each test in the '%tests' hash, compare each run's output the the regular expression defined for the test under the 'like' and 'unlike' functions, as appropriate. While this test suite covers a fair bit of ground (67% of pg_dump.c and quite a bit of the other files in src/bin/pg_dump), there is still quite a bit which remains to be added to provide better code coverage. Still, this is quite a bit better than we had, and has found a few bugs already (note that the CREATE TRANSFORM test is commented out, as it is currently failing). Idea for using the TAP system from Tom, though all of the code is mine. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/6bd356c33a3cf3a49313dc8638ea4bb066c4cf37 Modified Files -- src/bin/pg_dump/Makefile |3 + src/bin/pg_dump/pg_dump.c |2 +- src/bin/pg_dump/t/001_basic.pl | 42 + src/bin/pg_dump/t/002_pg_dump.pl | 2859 src/test/modules/Makefile |1 + src/test/modules/test_pg_dump/.gitignore |4 + src/test/modules/test_pg_dump/Makefile | 25 + src/test/modules/test_pg_dump/README |2 + .../modules/test_pg_dump/expected/test_pg_dump.out |6 + src/test/modules/test_pg_dump/sql/test_pg_dump.sql |1 + src/test/modules/test_pg_dump/t/001_base.pl| 535 .../modules/test_pg_dump/test_pg_dump--1.0.sql | 15 + src/test/modules/test_pg_dump/test_pg_dump.control |3 + 13 files changed, 3497 insertions(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: pg_dump performance and other fixes
pg_dump performance and other fixes Do not try to dump objects which do not have ACLs when only ACLs are being requested. This results in a significant performance improvement as we can avoid querying for further information on these objects when we don't need to. When limiting the components to dump for an extension, consider what components have been requested. Initially, we incorrectly hard-coded the components of the extension objects to dump, which would mean that we wouldn't dump some components even with they were asked for and in other cases we would dump components which weren't requested. Correct defaultACLs to use 'dump_contains' instead of 'dump'. The defaultACL is considered a member of the namespace and should be dumped based on the same set of components that the other objects in the schema are, not based on what we're dumping for the namespace itself (which might not include ACLs, if the namespace has just the default or initial ACL). Use DUMP_COMPONENT_ACL for from-initdb objects, to allow users to change their ACLs, should they wish to. This just extends what we are doing for the pg_catalog namespace to objects which are not members of namespaces. Due to column ACLs being treated a bit differently from other ACLs (they are actually reset to NULL when all privileges are revoked), adjust the query which gathers column-level ACLs to consider all of the ACL-relevant columns. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/5d589993cad212f7d556d52cc1e42fe18f65b057 Modified Files -- src/bin/pg_dump/pg_dump.c | 188 +++--- 1 file changed, 159 insertions(+), 29 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Only issue LOCK TABLE commands when necessary
Only issue LOCK TABLE commands when necessary Reviewing the cases where we need to LOCK a given table during a dump, it was pointed out by Tom that we really don't need to LOCK a table if we are only looking to dump the ACL for it, or certain other components. After reviewing the queries run for all of the component pieces, a list of components were determined to not require LOCK'ing of the table. This implements a check to avoid LOCK'ing those tables. Initial complaint from Rushabh Lathia, discussed with Robert and Tom, the patch is mine. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/e1b120a8cbb0f39a79926fd173f33e57202cdfa0 Modified Files -- src/bin/pg_dump/pg_dump.c | 5 - src/bin/pg_dump/pg_dump.h | 27 +++ 2 files changed, 31 insertions(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Remove various special checks around default roles
Remove various special checks around default roles Default roles really should be like regular roles, for the most part. This removes a number of checks that were trying to make default roles extra special by not allowing them to be used as regular roles. We still prevent users from creating roles in the "pg_" namespace or from altering roles which exist in that namespace via ALTER ROLE, as we can't preserve such changes, but otherwise the roles are very much like regular roles. Based on discussion with Robert and Tom. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/a89505fd21da337b81172871d8f65d9a4fa22a8b Modified Files -- src/backend/catalog/aclchk.c| 7 --- src/backend/commands/alter.c| 3 --- src/backend/commands/foreigncmds.c | 13 - src/backend/commands/policy.c | 5 - src/backend/commands/schemacmds.c | 4 src/backend/commands/tablecmds.c| 2 -- src/backend/commands/tablespace.c | 4 src/backend/commands/user.c | 11 --- src/backend/commands/variable.c | 7 --- src/test/regress/expected/rolenames.out | 18 +- src/test/regress/sql/rolenames.sql | 10 +- 11 files changed, 10 insertions(+), 74 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
Re: [COMMITTERS] pgsql: Reserve the "pg_" namespace for roles
Bruce, On Friday, April 29, 2016, Bruce Momjian wrote: > On Fri, Apr 8, 2016 at 08:56:34PM +0000, Stephen Frost wrote: > > Reserve the "pg_" namespace for roles > > > > This will prevent users from creating roles which begin with "pg_" and > > will check for those roles before allowing an upgrade using pg_upgrade. > > > > This will allow for default roles to be provided at initdb time. > > Nice you added the check to pg_upgrade, but I assume a pg_dumpall > restore is going to fail pretty badly, e.g. any pg_* object assignment > will fail. I guess there isn't much we can do to fix that. The pg_dumpall will work but will throw a warning. A restore will fail to recreate any pg_* roles and there could be follow-on errors from that, of course. I had pg_dumpall throw an error initially, but based on discussion that was considered too harsh. Thanks! Stephen
[COMMITTERS] pgsql: In recordExtensionInitPriv(), keep the scan til we're done with
In recordExtensionInitPriv(), keep the scan til we're done with it For reasons of sheer brain fade, we (I) was calling systable_endscan() immediately after systable_getnext() and expecting the tuple returned by systable_getnext() to still be valid. That's clearly wrong. Move the systable_endscan() down below the tuple usage. Discovered initially by Pavel Stehule and then also by Alvaro. Add a regression test based on Alvaro's testing. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/99f2f3c19ae7d6aa2950a9bdb549217c5a60d941 Modified Files -- src/backend/catalog/aclchk.c | 4 ++-- src/test/modules/test_extensions/Makefile | 6 +++--- src/test/modules/test_extensions/expected/test_extensions.out | 3 +++ src/test/modules/test_extensions/sql/test_extensions.sql | 4 src/test/modules/test_extensions/test_ext6--1.0.sql | 1 + src/test/modules/test_extensions/test_ext6.control| 5 + 6 files changed, 18 insertions(+), 5 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
Re: [COMMITTERS] pgsql: Fix pg_dump so pg_upgrade'ing an extension with simple opfamilie
* Tom Lane (t...@sss.pgh.pa.us) wrote: > Tom Lane writes: > > Fix pg_dump so pg_upgrade'ing an extension with simple opfamilies works. > > I see this has broken the buildfarm's pg_upgrade checks, though only in > HEAD which makes me suspicious that it's exposing a pre-existing bug. > Odd, because I definitely tested pg_upgrade here. Will dig into it > later this evening. My test shows, near the end: ERROR: zero-length delimited identifier at or near at character 40 STATEMENT: CREATE OPERATOR FAMILY "box_ops" USING ""; Not immediately seeing why it's unable to find the amname for box_ops though. Thanks! Stephen signature.asc Description: Digital signature
[COMMITTERS] pgsql: Disallow SET SESSION AUTHORIZATION pg_*
Disallow SET SESSION AUTHORIZATION pg_* As part of reserving the pg_* namespace for default roles and in line with SET ROLE and other previous efforts, disallow settings the role to a default/reserved role using SET SESSION AUTHORIZATION. These checks and restrictions on what is allowed regarding default / reserved roles are under debate, but it seems prudent to ensure that the existing checks at least cover the intended cases while the debate rages on. On me to clean it up if the consensus decision is to remove these checks. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/bfed4ab824789fd7c000286650d4498dccb05634 Modified Files -- src/backend/commands/variable.c | 4 1 file changed, 4 insertions(+) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Correct copyright for newly added genericdesc.c
Correct copyright for newly added genericdesc.c It's 2016 these days (no, not entirely sure how we got here either). Pointed out by Amit Langote Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/cd13471f2e9dee6d411cae3ddae72d0ad6b58c4d Modified Files -- src/backend/access/rmgrdesc/genericdesc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Prefix RLS regression test roles with 'regress_'
Prefix RLS regression test roles with 'regress_' To avoid any possible overlap with existing roles on a system when doing a 'make installcheck', use role names which start with 'regress_'. Pointed out by Tom. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/6c7b0388c568e3063c3d40a7d90e1bca9006d505 Modified Files -- src/test/regress/expected/rowsecurity.out | 828 +++--- src/test/regress/sql/rowsecurity.sql | 454 2 files changed, 641 insertions(+), 641 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Create default roles
Create default roles This creates an initial set of default roles which administrators may use to grant access to, historically, superuser-only functions. Using these roles instead of granting superuser access reduces the number of superuser roles required for a system. Documention for each of the default roles has been added to user-manag.sgml. Bump catversion to 201604082, as we had a commit that bumped it to 201604081 and another that set it back to 201604071... Reviews by José Luis Tallón and Robert Haas Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/7a542700df25eaf97b794bff63606176433dcdda Modified Files -- doc/src/sgml/func.sgml | 8 -- doc/src/sgml/user-manag.sgml| 51 + src/backend/utils/adt/misc.c| 8 -- src/include/catalog/catversion.h| 2 +- src/include/catalog/pg_authid.h | 8 +- src/test/regress/expected/rolenames.out | 5 src/test/regress/sql/rolenames.sql | 2 ++ 7 files changed, 76 insertions(+), 8 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Reserve the "pg_" namespace for roles
Reserve the "pg_" namespace for roles This will prevent users from creating roles which begin with "pg_" and will check for those roles before allowing an upgrade using pg_upgrade. This will allow for default roles to be provided at initdb time. Reviews by José Luis Tallón and Robert Haas Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/293007898d3fa5a815c1c5814df53627553f114d Modified Files -- doc/src/sgml/ref/psql-ref.sgml | 8 -- src/backend/catalog/aclchk.c| 7 + src/backend/catalog/catalog.c | 5 ++-- src/backend/commands/alter.c| 3 ++ src/backend/commands/foreigncmds.c | 13 + src/backend/commands/policy.c | 5 src/backend/commands/schemacmds.c | 4 +++ src/backend/commands/tablecmds.c| 2 ++ src/backend/commands/tablespace.c | 4 +++ src/backend/commands/user.c | 49 + src/backend/commands/variable.c | 3 ++ src/backend/utils/adt/acl.c | 39 ++ src/bin/pg_dump/pg_dumpall.c| 11 +++- src/bin/pg_upgrade/check.c | 40 +-- src/bin/psql/command.c | 4 +-- src/bin/psql/describe.c | 5 +++- src/bin/psql/describe.h | 2 +- src/bin/psql/help.c | 4 +-- src/include/utils/acl.h | 1 + src/test/regress/expected/rolenames.out | 20 ++ src/test/regress/sql/rolenames.sql | 10 +++ 21 files changed, 226 insertions(+), 13 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Fix improper usage of 'dump' bitmap
Fix improper usage of 'dump' bitmap Now that 'dump' is a bitmap, we can't simply set it to 'true'. Noticed while debugging the prior issue. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/fa6075e5515c6878b2c1fe1c6435dd7ed847857d Modified Files -- src/bin/pg_dump/pg_dump_sort.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: In dumpTable, re-instate the skipping logic
In dumpTable, re-instate the skipping logic Pretty sure I removed this based on some incorrect thinking that it was no longer possible to reach this point for a table which will not be dumped, but that's clearly wrong. Pointed out on IRC by Erik Rijkers. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/689f9a058854a1a32e994818dd6d79f49d8f8a1b Modified Files -- src/bin/pg_dump/pg_dump.c | 7 +++ 1 file changed, 7 insertions(+) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
Re: [COMMITTERS] pgsql: CREATE INDEX ... INCLUDING (column[, ...])
* Robert Haas (robertmh...@gmail.com) wrote: > On Fri, Apr 8, 2016 at 2:29 PM, Tom Lane wrote: > > Teodor Sigaev writes: > >> CREATE INDEX ... INCLUDING (column[, ...]) > > > > Buildfarm members that don't like // comments are dying on this bit > > in tuplesort.c: > > > > state->nKeys = IndexRelationGetNumberOfKeyAttributes(indexRel); > > //FIXME > > > > I assume that the problem here is larger than just failure to adhere to > > C89 comment style. Was this patch really ready to commit? I'm not very > > happy that such a large patch went from "Needs review" to "Committed" in > > the blink of an eye on the very last commitfest day ... and artifacts like > > this aren't doing anything to increase my confidence in it. > > +1. I wonder if this should be reverted entirely. This also broke pg_dump when connecting to pre-9.6 systems. That's a pretty easy fix and I was just about to push a fix for that, but will hold off if this is going to be reverted.. Thanks! Stephen signature.asc Description: Digital signature
[COMMITTERS] pgsql: GRANT rights to CURRENT_USER instead of adding roles
GRANT rights to CURRENT_USER instead of adding roles We shouldn't be adding roles during the regression tests as that can cause back-to-back installcheck runs to fail and users running the regression tests likley don't want those extra roles. Pointed out by Tom Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/6928484bda454f9ab2456d385b2d317f18b6bf1a Modified Files -- src/test/regress/expected/init_privs.out | 7 +++ src/test/regress/sql/init_privs.sql | 9 - 2 files changed, 7 insertions(+), 9 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Bump catversion for pg_dump dump catalog ACL patches
Bump catversion for pg_dump dump catalog ACL patches Pointed out by Tom. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/29dd1504a12f324c75f6b5ce8863505e499633ec Modified Files -- src/include/catalog/catversion.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
Re: [COMMITTERS] pgsql: Use GRANT system to manage access to sensitive functions
* Tom Lane (t...@sss.pgh.pa.us) wrote: > Stephen Frost writes: > > Use GRANT system to manage access to sensitive functions > > This patch series seems approximately three catversion bumps > shy of a load ... Blargh. I told myself at three different times tonight to remember to bump catversion. Apologies, will do so momentairly. Thanks! Stephen signature.asc Description: Digital signature
[COMMITTERS] pgsql: In pg_dump, split "dump" into "dump" and "dump_contains"
In pg_dump, split "dump" into "dump" and "dump_contains" Historically, the "dump" component of the namespace has been used to decide if the objects inside of the namespace should be dumped also. Given that "dump" is now a bitmask and may be partial, and we may want to dump out all components of the namespace object but only some of the components of objects contained in the namespace, create a "dump_contains" bitmask which will represent what components of the objects inside of a namespace should be dumped out. No behavior change here, but in preparation for a change where we will dump out just the ACLs of objects in pg_catalog, but we might not dump out the ACL of the pg_catalog namespace itself (for instance, when it hasn't been changed from the value set at initdb time). Reviews by Alexander Korotkov, Jose Luis Tallon Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/d217b2c360cb9a746b4ef122c568bdfedb6d726e Modified Files -- src/bin/pg_dump/pg_dump.c | 23 +-- src/bin/pg_dump/pg_dump.h | 3 ++- 2 files changed, 15 insertions(+), 11 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Add new catalog called pg_init_privs
Add new catalog called pg_init_privs This new catalog holds the privileges which the system was initialized with at initdb time, along with any permissions set by extensions at CREATE EXTENSION time. This allows pg_dump (and any other similar use-cases) to detect when the privileges set on initdb-created or extension-created objects have been changed from what they were set to at initdb/extension-creation time and handle those changes appropriately. Reviews by Alexander Korotkov, Jose Luis Tallon Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/6c268df1276e9dd73e4d2cc89cf8787e8f186bda Modified Files -- doc/src/sgml/catalogs.sgml | 108 + src/backend/catalog/Makefile | 2 +- src/backend/catalog/aclchk.c | 149 + src/backend/catalog/dependency.c | 46 - src/bin/initdb/initdb.c| 143 +++ src/include/catalog/indexing.h | 3 + src/include/catalog/pg_init_privs.h| 101 +++ src/test/regress/expected/sanity_check.out | 1 + 8 files changed, 549 insertions(+), 4 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: In pg_dump, include pg_catalog and extension ACLs, if changed
In pg_dump, include pg_catalog and extension ACLs, if changed Now that all of the infrastructure exists, add in the ability to dump out the ACLs of the objects inside of pg_catalog or the ACLs for objects which are members of extensions, but only if they have been changed from their original values. The original values are tracked in pg_init_privs. When pg_dump'ing 9.6-and-above databases, we will dump out the ACLs for all objects in pg_catalog and the ACLs for all extension members, where the ACL has been changed from the original value which was set during either initdb or CREATE EXTENSION. This should not change dumps against pre-9.6 databases. Reviews by Alexander Korotkov, Jose Luis Tallon Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/23f34fa4ba358671adab16773e79c17c92cbc870 Modified Files -- doc/src/sgml/extend.sgml | 21 + src/backend/catalog/aclchk.c | 17 +- src/backend/utils/adt/pg_upgrade_support.c | 12 + src/bin/initdb/initdb.c|6 +- src/bin/pg_dump/dumputils.c| 274 ++- src/bin/pg_dump/dumputils.h|9 +- src/bin/pg_dump/pg_dump.c | 1077 +++- src/bin/pg_dump/pg_dump.h | 24 + src/bin/pg_dump/pg_dumpall.c |6 +- src/include/catalog/binary_upgrade.h |2 + src/include/catalog/pg_proc.h |2 + src/test/regress/expected/init_privs.out | 13 + src/test/regress/parallel_schedule |2 +- src/test/regress/serial_schedule |1 + src/test/regress/sql/init_privs.sql| 11 + 15 files changed, 1268 insertions(+), 209 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Use GRANT system to manage access to sensitive functions
Use GRANT system to manage access to sensitive functions Now that pg_dump will properly dump out any ACL changes made to functions which exist in pg_catalog, switch to using the GRANT system to manage access to those functions. This means removing 'if (!superuser()) ereport()' checks from the functions themselves and then REVOKEing EXECUTE right from 'public' for these functions in system_views.sql. Reviews by Alexander Korotkov, Jose Luis Tallon Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/1574783b4ced0356fbc626af1a1a469faa6b41e1 Modified Files -- doc/src/sgml/backup.sgml | 8 +++-- doc/src/sgml/func.sgml | 19 ++-- doc/src/sgml/monitoring.sgml | 12 +--- src/backend/access/transam/xlogfuncs.c | 56 +- src/backend/catalog/system_views.sql | 21 + src/backend/postmaster/pgstat.c| 24 ++- src/backend/utils/adt/misc.c | 16 -- 7 files changed, 81 insertions(+), 75 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: In pg_dump, use a bitmap to represent what to include
In pg_dump, use a bitmap to represent what to include pg_dump has historically used a simple boolean 'dump' value to indicate if a given object should be included in the dump or not. Instead, use a bitmap which breaks down the components of an object into their distinct pieces and use that bitmap to only include the components requested. This does not include any behavioral change, but is in preperation for the change to dump out just ACLs for objects in pg_catalog. Reviews by Alexander Korotkov, Jose Luis Tallon Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/a9f0e8e5a2e779a888988cb64479a6723f668c84 Modified Files -- src/bin/pg_dump/common.c |2 +- src/bin/pg_dump/pg_dump.c | 1502 - src/bin/pg_dump/pg_dump.h | 14 +- 3 files changed, 833 insertions(+), 685 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Fix typo in pg_regress.c
Fix typo in pg_regress.c s/afer/after Pointed out by Andreas 'ads' Scherbaum Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/62b5cd234ba982f71f2501f405a26ed80c92a229 Modified Files -- src/test/regress/pg_regress.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Reset plan->row_security_env and planUserId
Reset plan->row_security_env and planUserId In the plancache, we check if the environment we planned the query under has changed in a way which requires us to re-plan, such as when the user for whom the plan was prepared changes and RLS is being used (and, therefore, there may be different policies to apply). Unfortunately, while those values were set and checked, they were not being reset when the query was re-planned and therefore, in cases where we change role, re-plan, and then change role again, we weren't re-planning again. This leads to potentially incorrect policies being applied in cases where role-specific policies are used and a given query is planned under one role and then executed under other roles, which could happen under security definer functions or when a common user and query is planned initially and then re-used across multiple SET ROLEs. Further, extensions which made use of CopyCachedPlan() may suffer from similar issues as the RLS-related fields were not properly copied as part of the plan and therefore RevalidateCachedQuery() would copy in the current settings without invalidating the query. Fix by using the same approach used for 'search_path', where we set the correct values in CompleteCachedPlan(), check them early on in RevalidateCachedQuery() and then properly reset them if re-planning. Also, copy through the values during CopyCachedPlan(). Pointed out by Ashutosh Bapat. Reviewed by Michael Paquier. Back-patch to 9.5 where RLS was introduced. Security: CVE-2016-2193 Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/db69e58a0642ef7fa46d62f6c4cf2460c3a1b41b Modified Files -- src/backend/utils/cache/plancache.c | 40 --- src/test/regress/expected/rowsecurity.out | 14 +++ src/test/regress/sql/rowsecurity.sql | 9 +++ 3 files changed, 49 insertions(+), 14 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Reset plan->row_security_env and planUserId
Reset plan->row_security_env and planUserId In the plancache, we check if the environment we planned the query under has changed in a way which requires us to re-plan, such as when the user for whom the plan was prepared changes and RLS is being used (and, therefore, there may be different policies to apply). Unfortunately, while those values were set and checked, they were not being reset when the query was re-planned and therefore, in cases where we change role, re-plan, and then change role again, we weren't re-planning again. This leads to potentially incorrect policies being applied in cases where role-specific policies are used and a given query is planned under one role and then executed under other roles, which could happen under security definer functions or when a common user and query is planned initially and then re-used across multiple SET ROLEs. Further, extensions which made use of CopyCachedPlan() may suffer from similar issues as the RLS-related fields were not properly copied as part of the plan and therefore RevalidateCachedQuery() would copy in the current settings without invalidating the query. Fix by using the same approach used for 'search_path', where we set the correct values in CompleteCachedPlan(), check them early on in RevalidateCachedQuery() and then properly reset them if re-planning. Also, copy through the values during CopyCachedPlan(). Pointed out by Ashutosh Bapat. Reviewed by Michael Paquier. Back-patch to 9.5 where RLS was introduced. Security: CVE-2016-2193 Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/86ebf30fd6d8964bbd5d48db053b0a7ff709a0d7 Modified Files -- src/backend/utils/cache/plancache.c | 41 --- src/test/regress/expected/rowsecurity.out | 14 +++ src/test/regress/sql/rowsecurity.sql | 9 +++ 3 files changed, 49 insertions(+), 15 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
Re: [COMMITTERS] pgsql: Improve internationalization of messages involving type names
Alvaro, * Alvaro Herrera (alvhe...@alvh.no-ip.org) wrote: > Improve internationalization of messages involving type names > > Change the slightly different variations of the message > function FOO must return type BAR > to a single wording, removing the variability in type name so that they > all create a single translation entry; since the type name is not to be > translated, there's no point in it being part of the message anyway. > > Also, change them all to use the same quoting convention, namely that > the function name is not to be quoted but the type name is. (I'm not > quite sure why this is so, but it's the clear majority.) > > Some similar messages such as "encoding conversion function FOO must ..." > are also changed. Buildfarm is pretty upset with this one, in particular: http://git.postgresql.org/gitweb/?p=postgresql.git;a=blobdiff;f=src/backend/commands/event_trigger.c;h=3735d44ee9d0b89f35ca8e8fb00b1a8dbbaa6362;hp=3f52ad836b4a2be1d95047f0949607d8cbbb283d;hb=59a2111;hpb=559e7a0a6d4450c09825055e3d255d30ee869c67 Thanks! Stephen signature.asc Description: Digital signature
[COMMITTERS] pgsql: Avoid incorrectly indicating exclusion constraint wait
Avoid incorrectly indicating exclusion constraint wait INSERT ... ON CONFLICT's precheck may have to wait on the outcome of another insertion, which may or may not itself be a speculative insertion. This wait is not necessarily associated with an exclusion constraint, but was always reported that way in log messages if the wait happened to involve a tuple that had no speculative token. Initially discovered through use of ON CONFLICT DO NOTHING, where spurious references to exclusion constraints in log messages were more likely. Patch by Peter Geoghegan. Reviewed by Julien Rouhaud. Back-patch to 9.5 where INSERT ... ON CONFLICT was added. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/fd658dbb300456b393536802d1145a9cea7b25d6 Modified Files -- src/backend/executor/execIndexing.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Avoid incorrectly indicating exclusion constraint wait
Avoid incorrectly indicating exclusion constraint wait INSERT ... ON CONFLICT's precheck may have to wait on the outcome of another insertion, which may or may not itself be a speculative insertion. This wait is not necessarily associated with an exclusion constraint, but was always reported that way in log messages if the wait happened to involve a tuple that had no speculative token. Initially discovered through use of ON CONFLICT DO NOTHING, where spurious references to exclusion constraints in log messages were more likely. Patch by Peter Geoghegan. Reviewed by Julien Rouhaud. Back-patch to 9.5 where INSERT ... ON CONFLICT was added. Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/3f14d8d59457f98b8ddbbc29cffae9260037aad5 Modified Files -- src/backend/executor/execIndexing.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Make viewquery a copy in rewriteTargetView()
Make viewquery a copy in rewriteTargetView() Rather than expect the Query returned by get_view_query() to be read-only and then copy bits and pieces of it out, simply copy the entire structure when we get it. This addresses an issue where AcquireRewriteLocks, which is called by acquireLocksOnSubLinks(), scribbles on the parsetree passed in, which was actually an entry in relcache, leading to segfaults with certain view definitions. This also future-proofs us a bit for anyone adding more code to this path. The acquireLocksOnSubLinks() was added in commit c3e0ddd40. Back-patch to 9.3 as that commit was. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/6f8cb1e23485bd6d45e8865760436e1a5ce65a6d Modified Files -- src/backend/rewrite/rewriteHandler.c | 34 - src/test/regress/expected/updatable_views.out | 67 + src/test/regress/sql/updatable_views.sql | 44 3 files changed, 133 insertions(+), 12 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Make viewquery a copy in rewriteTargetView()
Make viewquery a copy in rewriteTargetView() Rather than expect the Query returned by get_view_query() to be read-only and then copy bits and pieces of it out, simply copy the entire structure when we get it. This addresses an issue where AcquireRewriteLocks, which is called by acquireLocksOnSubLinks(), scribbles on the parsetree passed in, which was actually an entry in relcache, leading to segfaults with certain view definitions. This also future-proofs us a bit for anyone adding more code to this path. The acquireLocksOnSubLinks() was added in commit c3e0ddd40. Back-patch to 9.3 as that commit was. Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/496943ec2b6de0f22cd9e18f673e13635b5972ef Modified Files -- src/backend/rewrite/rewriteHandler.c | 34 - src/test/regress/expected/updatable_views.out | 67 + src/test/regress/sql/updatable_views.sql | 44 3 files changed, 133 insertions(+), 12 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Make viewquery a copy in rewriteTargetView()
Make viewquery a copy in rewriteTargetView() Rather than expect the Query returned by get_view_query() to be read-only and then copy bits and pieces of it out, simply copy the entire structure when we get it. This addresses an issue where AcquireRewriteLocks, which is called by acquireLocksOnSubLinks(), scribbles on the parsetree passed in, which was actually an entry in relcache, leading to segfaults with certain view definitions. This also future-proofs us a bit for anyone adding more code to this path. The acquireLocksOnSubLinks() was added in commit c3e0ddd40. Back-patch to 9.3 as that commit was. Branch -- REL9_3_STABLE Details --- http://git.postgresql.org/pg/commitdiff/4271ed3860e3885d3fbed1ea9ee4f058e8763104 Modified Files -- src/backend/rewrite/rewriteHandler.c | 29 +++ src/test/regress/expected/updatable_views.out | 67 + src/test/regress/sql/updatable_views.sql | 44 3 files changed, 130 insertions(+), 10 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Make viewquery a copy in rewriteTargetView()
Make viewquery a copy in rewriteTargetView() Rather than expect the Query returned by get_view_query() to be read-only and then copy bits and pieces of it out, simply copy the entire structure when we get it. This addresses an issue where AcquireRewriteLocks, which is called by acquireLocksOnSubLinks(), scribbles on the parsetree passed in, which was actually an entry in relcache, leading to segfaults with certain view definitions. This also future-proofs us a bit for anyone adding more code to this path. The acquireLocksOnSubLinks() was added in commit c3e0ddd40. Back-patch to 9.3 as that commit was. Branch -- REL9_4_STABLE Details --- http://git.postgresql.org/pg/commitdiff/f02137da88c49125a20d7c51ae9932e47eb61f93 Modified Files -- src/backend/rewrite/rewriteHandler.c | 34 - src/test/regress/expected/updatable_views.out | 67 + src/test/regress/sql/updatable_views.sql | 44 3 files changed, 133 insertions(+), 12 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Improve CREATE POLICY documentation
Improve CREATE POLICY documentation Clarify that SELECT policies are now applied when SELECT rights are required for a given query, even if the query is an UPDATE or DELETE query. Pointed out by Noah. Additionally, note the risk regarding concurrently open transactions where a relation which controls access to the rows of another relation are updated and the rows of the primary relation are also being modified. Pointed out by Peter Geoghegan. Back-patch to 9.5. Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/46ae55c372761af5e02082ea934bebcba98040a4 Modified Files -- doc/src/sgml/ref/create_policy.sgml | 113 ++- 1 file changed, 86 insertions(+), 27 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Improve CREATE POLICY documentation
Improve CREATE POLICY documentation Clarify that SELECT policies are now applied when SELECT rights are required for a given query, even if the query is an UPDATE or DELETE query. Pointed out by Noah. Additionally, note the risk regarding concurrently open transactions where a relation which controls access to the rows of another relation are updated and the rows of the primary relation are also being modified. Pointed out by Peter Geoghegan. Back-patch to 9.5. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/43cd468cf01007f39312af05c4c92ceb6de8afd8 Modified Files -- doc/src/sgml/ref/create_policy.sgml | 113 ++- 1 file changed, 86 insertions(+), 27 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Collect the global OR of hasRowSecurity flags for plancache
Collect the global OR of hasRowSecurity flags for plancache We carry around information about if a given query has row security or not to allow the plancache to use that information to invalidate a planned query in the event that the environment changes. Previously, the flag of one of the subqueries was simply being copied into place to indicate if the query overall included RLS components. That's wrong as we need the global OR of all subqueries. Fix by changing the code to match how fireRIRules works, which is results in OR'ing all of the flags. Noted by Tom. Back-patch to 9.5 where RLS was introduced. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/e5e11c8cca7ae298895430102217fa6d77cfb2a3 Modified Files -- src/backend/optimizer/plan/planner.c |3 +- src/backend/optimizer/plan/setrefs.c |3 +- src/test/regress/expected/rowsecurity.out | 154 - src/test/regress/sql/rowsecurity.sql | 24 - 4 files changed, 180 insertions(+), 4 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Collect the global OR of hasRowSecurity flags for plancache
Collect the global OR of hasRowSecurity flags for plancache We carry around information about if a given query has row security or not to allow the plancache to use that information to invalidate a planned query in the event that the environment changes. Previously, the flag of one of the subqueries was simply being copied into place to indicate if the query overall included RLS components. That's wrong as we need the global OR of all subqueries. Fix by changing the code to match how fireRIRules works, which is results in OR'ing all of the flags. Noted by Tom. Back-patch to 9.5 where RLS was introduced. Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/651e2ba74af997c2952672397828636dc6c6d017 Modified Files -- src/backend/optimizer/plan/planner.c |3 +- src/backend/optimizer/plan/setrefs.c |3 +- src/test/regress/expected/rowsecurity.out | 154 - src/test/regress/sql/rowsecurity.sql | 24 - 4 files changed, 180 insertions(+), 4 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Handle policies during DROP OWNED BY
Handle policies during DROP OWNED BY DROP OWNED BY handled GRANT-based ACLs but was not removing roles from policies. Fix that by having DROP OWNED BY remove the role specified from the list of roles the policy (or policies) apply to, or the entire policy (or policies) if it only applied to the role specified. As with ACLs, the DROP OWNED BY caller must have permission to modify the policy or a WARNING is thrown and no change is made to the policy. Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/fda18e46a65196b98d6ca4ce4911085b0d2f182f Modified Files -- src/backend/catalog/pg_shdepend.c | 13 ++ src/backend/commands/policy.c | 256 + src/include/commands/policy.h |2 + src/test/regress/expected/rowsecurity.out | 14 ++ src/test/regress/sql/rowsecurity.sql | 18 ++ 5 files changed, 303 insertions(+) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Handle policies during DROP OWNED BY
Handle policies during DROP OWNED BY DROP OWNED BY handled GRANT-based ACLs but was not removing roles from policies. Fix that by having DROP OWNED BY remove the role specified from the list of roles the policy (or policies) apply to, or the entire policy (or policies) if it only applied to the role specified. As with ACLs, the DROP OWNED BY caller must have permission to modify the policy or a WARNING is thrown and no change is made to the policy. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/833728d4c8832f1d37e7aeaa723c8bc4045df32e Modified Files -- src/backend/catalog/pg_shdepend.c | 13 ++ src/backend/commands/policy.c | 256 + src/include/commands/policy.h |2 + src/test/regress/expected/rowsecurity.out | 14 ++ src/test/regress/sql/rowsecurity.sql | 18 ++ 5 files changed, 303 insertions(+) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Handle dependencies properly in ALTER POLICY
Handle dependencies properly in ALTER POLICY ALTER POLICY hadn't fully considered partial policy alternation (eg: change just the roles on the policy, or just change one of the expressions) when rebuilding the dependencies. Instead, it would happily remove all dependencies which existed for the policy and then only recreate the dependencies for the objects referred to in the specific ALTER POLICY command. Correct that by extracting and building the dependencies for all objects referenced by the policy, regardless of if they were provided as part of the ALTER POLICY command or were already in place as part of the pre-existing policy. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/ed8bec915ec570bd90d86710392fe0c181fd08fe Modified Files -- src/backend/commands/policy.c | 97 + src/test/regress/expected/rowsecurity.out | 43 + src/test/regress/sql/rowsecurity.sql | 31 + 3 files changed, 171 insertions(+) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Handle dependencies properly in ALTER POLICY
Handle dependencies properly in ALTER POLICY ALTER POLICY hadn't fully considered partial policy alternation (eg: change just the roles on the policy, or just change one of the expressions) when rebuilding the dependencies. Instead, it would happily remove all dependencies which existed for the policy and then only recreate the dependencies for the objects referred to in the specific ALTER POLICY command. Correct that by extracting and building the dependencies for all objects referenced by the policy, regardless of if they were provided as part of the ALTER POLICY command or were already in place as part of the pre-existing policy. Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/12a54c888cf7bd9c37c4ce420e84cb52debe0184 Modified Files -- src/backend/commands/policy.c | 97 + src/test/regress/expected/rowsecurity.out | 43 + src/test/regress/sql/rowsecurity.sql | 31 + 3 files changed, 171 insertions(+) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
Re: [COMMITTERS] pgsql: Improve pageinspect module
* Teodor Sigaev (teo...@sigaev.ru) wrote: > Improve pageinspect module > > Now pageinspect can show data stored in the heap tuple. The buildfarm isn't happy with this change.. Thanks! Stephen signature.asc Description: Digital signature
[COMMITTERS] pgsql: Correct sepgsql docs with regard to RLS
Correct sepgsql docs with regard to RLS The sepgsql docs included a comment that PG doesn't support RLS. That is only true for versions prior to 9.5. Update the docs for 9.5 and master to say that PG supports RLS but that sepgsql does not yet. Pointed out by Heikki. Back-patch to 9.5 Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/42aa1c032e3520d608a1e89abbf36409b022d4b7 Modified Files -- doc/src/sgml/sepgsql.sgml |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Correct sepgsql docs with regard to RLS
Correct sepgsql docs with regard to RLS The sepgsql docs included a comment that PG doesn't support RLS. That is only true for versions prior to 9.5. Update the docs for 9.5 and master to say that PG supports RLS but that sepgsql does not yet. Pointed out by Heikki. Back-patch to 9.5 Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/d324c7226104266bf9fd57380a0703e40ba24fd4 Modified Files -- doc/src/sgml/sepgsql.sgml |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers
[COMMITTERS] pgsql: Set include_realm=1 default in parse_hba_line
Set include_realm=1 default in parse_hba_line With include_realm=1 being set down in parse_hba_auth_opt, if multiple options are passed on the pg_hba line, such as: host all all0.0.0.0/0gss include_realm=0 krb_realm=XYZ.COM We would mistakenly reset include_realm back to 1. Instead, we need to set include_realm=1 up in parse_hba_line, prior to parsing any of the additional options. Discovered by Jeff McCormick during testing. Bug introduced by 9a08841. Back-patch to 9.5 Branch -- REL9_5_STABLE Details --- http://git.postgresql.org/pg/commitdiff/695012a0d585844130bf3d82ad0b4ebe0b7bf581 Modified Files -- src/backend/libpq/hba.c | 26 +- 1 file changed, 13 insertions(+), 13 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers