[COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
Add pg_audit, an auditing extension This extension provides detailed logging classes, ability to control logging at a per-object level, and includes fully-qualified object names for logged statements (DML and DDL) in independent fields of the log output. Authors: Ian Barwick, Abhijit Menon-Sen,

[COMMITTERS] pgsql: Support expanded objects, particularly arrays, for better perf

2015-05-14 Thread Tom Lane
Support expanded objects, particularly arrays, for better performance. This patch introduces the ability for complex datatypes to have an in-memory representation that is different from their on-disk format. On-disk formats are typically optimized for minimal size, and in any case they can't

[COMMITTERS] pgsql: Suppress uninitialized-variable warning.

2015-05-14 Thread Tom Lane
Suppress uninitialized-variable warning. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/6c9e93d3ffbf99435636103ad69d6469c64e2aef Modified Files -- contrib/pg_audit/pg_audit.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- Sent via

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
* Tom Lane (t...@sss.pgh.pa.us) wrote: Stephen Frost sfr...@snowman.net writes: We don't currently drop the role though at the end though. Quite aside from any security risks, that means that running make installcheck twice in a row fails. Please fix. Right, will do, though one kind of

[COMMITTERS] pgsql: Docs: fix erroneous claim about max byte length of GB18030.

2015-05-14 Thread Tom Lane
Docs: fix erroneous claim about max byte length of GB18030. This encoding has characters up to 4 bytes long, not 2. Branch -- REL9_1_STABLE Details --- http://git.postgresql.org/pg/commitdiff/66184871735051450a0b551e7af505f276736bff Modified Files --

[COMMITTERS] pgsql: Docs: fix erroneous claim about max byte length of GB18030.

2015-05-14 Thread Tom Lane
Docs: fix erroneous claim about max byte length of GB18030. This encoding has characters up to 4 bytes long, not 2. Branch -- REL9_0_STABLE Details --- http://git.postgresql.org/pg/commitdiff/af4a9c19c23acddeb139bbedafeb90d987fb91bf Modified Files --

[COMMITTERS] pgsql: Docs: fix erroneous claim about max byte length of GB18030.

2015-05-14 Thread Tom Lane
Docs: fix erroneous claim about max byte length of GB18030. This encoding has characters up to 4 bytes long, not 2. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/333d0779627a6c6125c018ea39da4427d3bdd93f Modified Files -- doc/src/sgml/charset.sgml |

[COMMITTERS] pgsql: Docs: fix erroneous claim about max byte length of GB18030.

2015-05-14 Thread Tom Lane
Docs: fix erroneous claim about max byte length of GB18030. This encoding has characters up to 4 bytes long, not 2. Branch -- REL9_3_STABLE Details --- http://git.postgresql.org/pg/commitdiff/13a2b7bf6ef6232909ade08fda28221f91a3d905 Modified Files --

[COMMITTERS] pgsql: Docs: fix erroneous claim about max byte length of GB18030.

2015-05-14 Thread Tom Lane
Docs: fix erroneous claim about max byte length of GB18030. This encoding has characters up to 4 bytes long, not 2. Branch -- REL9_2_STABLE Details --- http://git.postgresql.org/pg/commitdiff/cde3e743cdc6317711913c0cee8a8c56f49ea87c Modified Files --

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Thom Brown
On 14 May 2015 at 17:45, Stephen Frost sfr...@snowman.net wrote: Thom, * Thom Brown (t...@linux.com) wrote: On 14 May 2015 at 15:36, Stephen Frost sfr...@snowman.net wrote: Add pg_audit, an auditing extension A quick glance shows a parameter called pg_audit.log_statement_once, which isn't

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
Thom, * Thom Brown (t...@linux.com) wrote: On 14 May 2015 at 17:45, Stephen Frost sfr...@snowman.net wrote: Is there somewhere else they're missing from? Ah, my apologies. I can see from the file date that pgaudit.html is dated 2 weeks ago, so I'm looking at an old copy. Not sure what

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Tom Lane
Stephen Frost sfr...@snowman.net writes: * Tom Lane (t...@sss.pgh.pa.us) wrote: There are several more crashes in the BF now. They're not at initial library load AFAICS. Hard to tell if it's platform-specific or just randomly fails sometimes. Have you tried valgrind to see if there's

[COMMITTERS] pgsql: Docs: fix erroneous claim about max byte length of GB18030.

2015-05-14 Thread Tom Lane
Docs: fix erroneous claim about max byte length of GB18030. This encoding has characters up to 4 bytes long, not 2. Branch -- REL9_4_STABLE Details --- http://git.postgresql.org/pg/commitdiff/f173fb8a6df82c6146a1ce812a8cdb4fdca9943d Modified Files --

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
* Tom Lane (t...@sss.pgh.pa.us) wrote: Stephen Frost sfr...@snowman.net writes: * Tom Lane (t...@sss.pgh.pa.us) wrote: There are several more crashes in the BF now. They're not at initial library load AFAICS. Hard to tell if it's platform-specific or just randomly fails sometimes. Have

[COMMITTERS] pgsql: Fix portability issue in pg_audit.

2015-05-14 Thread Tom Lane
Fix portability issue in pg_audit. %ld is not a portable way to print int64's. This may explain the buildfarm crashes we're seeing --- it seems to make dromedary happy, at least. Branch -- master Details ---

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
* Tom Lane (t...@sss.pgh.pa.us) wrote: Stephen Frost sfr...@snowman.net writes: And... I busted the buildfarm. Will fix. -- Load pg_audit module create extension pg_audit; + ERROR: pg_audit must be loaded via shared_preload_libraries This seems like a rather poorly thought-through

Re: [COMMITTERS] pgsql: Further fixes for the buildfarm for pg_audit

2015-05-14 Thread Stephen Frost
* Tom Lane (t...@sss.pgh.pa.us) wrote: Stephen Frost sfr...@snowman.net writes: Further fixes for the buildfarm for pg_audit It still doesn't work. Have you actually attempted to run the test in an installation that doesn't have the module preloaded? Actually, I had fixed it, I just

Re: [COMMITTERS] pgsql: Further fixes for the buildfarm for pg_audit

2015-05-14 Thread Tom Lane
Stephen Frost sfr...@snowman.net writes: Further fixes for the buildfarm for pg_audit It still doesn't work. Have you actually attempted to run the test in an installation that doesn't have the module preloaded? regards, tom lane -- Sent via pgsql-committers mailing

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Thom Brown
On 14 May 2015 at 15:36, Stephen Frost sfr...@snowman.net wrote: Add pg_audit, an auditing extension This extension provides detailed logging classes, ability to control logging at a per-object level, and includes fully-qualified object names for logged statements (DML and DDL) in independent

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
Thom, * Thom Brown (t...@linux.com) wrote: On 14 May 2015 at 15:36, Stephen Frost sfr...@snowman.net wrote: Add pg_audit, an auditing extension A quick glance shows a parameter called pg_audit.log_statement_once, which isn't mentioned in the docs. Also, pg_audit.log_level isn't in the

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
* Stephen Frost (sfr...@snowman.net) wrote: Add pg_audit, an auditing extension And... I busted the buildfarm. Will fix. Thanks, Stephen signature.asc Description: Digital signature

[COMMITTERS] pgsql: Fix buildfarm with regard to pg_audit

2015-05-14 Thread Stephen Frost
Fix buildfarm with regard to pg_audit Remove the check that pg_audit be installed by shared_preload_libraries as that's not going to work when running the regressions tests in the buildfarm. That check was primairly a nice to have and isn't required anyway. Branch -- master Details ---

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Tom Lane
Stephen Frost sfr...@snowman.net writes: I've pushed a change which should clean it up by simply loading the module after each reconnects is done, more-or-less simulating having it be in shared_preload_libraries. It also wasn't using the correct database for reconnecting. I'll keep an eye

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Tom Lane
Stephen Frost sfr...@snowman.net writes: And... I busted the buildfarm. Will fix. -- Load pg_audit module create extension pg_audit; + ERROR: pg_audit must be loaded via shared_preload_libraries This seems like a rather poorly thought-through error check. It will break not only the

[COMMITTERS] pgsql: Further fixes for the buildfarm for pg_audit

2015-05-14 Thread Stephen Frost
Further fixes for the buildfarm for pg_audit Also, use a function to load the extension ahead of all other calls, simulating load from shared_libraries_preload, to make sure the hooks are in place before logging start. Branch -- master Details ---

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
* Tom Lane (t...@sss.pgh.pa.us) wrote: Stephen Frost sfr...@snowman.net writes: * Tom Lane (t...@sss.pgh.pa.us) wrote: Quite aside from any security risks, that means that running make installcheck twice in a row fails. Please fix. Right, will do, though one kind of requires the other

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Tom Lane
Stephen Frost sfr...@snowman.net writes: * Tom Lane (t...@sss.pgh.pa.us) wrote: + ERROR: pg_audit must be loaded via shared_preload_libraries This seems like a rather poorly thought-through error check. It will break not only the buildfarm but any dump/restore scenario. You really can't

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
* Tom Lane (t...@sss.pgh.pa.us) wrote: Stephen Frost sfr...@snowman.net writes: I've pushed a change which should clean it up by simply loading the module after each reconnects is done, more-or-less simulating having it be in shared_preload_libraries. It also wasn't using the correct

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Tom Lane
Stephen Frost sfr...@snowman.net writes: We don't currently drop the role though at the end though. Quite aside from any security risks, that means that running make installcheck twice in a row fails. Please fix. Will investigate that, suggestions certainly welcome. Looks like there's a

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Tom Lane
Stephen Frost sfr...@snowman.net writes: * Tom Lane (t...@sss.pgh.pa.us) wrote: Quite aside from any security risks, that means that running make installcheck twice in a row fails. Please fix. Right, will do, though one kind of requires the other (we can't drop the only user we know how to

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
Thom, * Thom Brown (t...@linux.com) wrote: A quick glance shows a parameter called pg_audit.log_statement_once, which isn't mentioned in the docs. Also, pg_audit.log_level isn't in the logs, but seems to offer a superset of functionality to pg_audit.log_notice, which doesn't appear as a

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
* Tom Lane (t...@sss.pgh.pa.us) wrote: Stephen Frost sfr...@snowman.net writes: * Tom Lane (t...@sss.pgh.pa.us) wrote: + ERROR: pg_audit must be loaded via shared_preload_libraries This seems like a rather poorly thought-through error check. It will break not only the buildfarm but

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
* Tom Lane (t...@sss.pgh.pa.us) wrote: Stephen Frost sfr...@snowman.net writes: * Tom Lane (t...@sss.pgh.pa.us) wrote: Quite aside from any security risks, that means that running make installcheck twice in a row fails. Please fix. Right, will do, though one kind of requires the other

Re: [COMMITTERS] pgsql: Fix portability issue in pg_audit.

2015-05-14 Thread Tom Lane
Alvaro Herrera alvhe...@2ndquadrant.com writes: Tom Lane wrote: %ld is not a portable way to print int64's. This may explain the buildfarm crashes we're seeing --- it seems to make dromedary happy, at least. FWIW you could use %zd for translatability, assuming we ever get pg_audit

Re: [COMMITTERS] pgsql: Make repeated 'make installcheck' runs work

2015-05-14 Thread Tom Lane
Stephen Frost sfr...@snowman.net writes: Make repeated 'make installcheck' runs work Much better, thanks. BTW, isn't the pg_audit.conf file useless now? regards, tom lane -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to

[COMMITTERS] pgsql: Improve pg_audit regression tests

2015-05-14 Thread Stephen Frost
Improve pg_audit regression tests Instead of creating a new superuser role, extract out what the current user is and use that user instead. Further, clean up and drop all objects created by the regression test. Pointed out by Tom. Branch -- master Details ---

[COMMITTERS] pgsql: Make repeated 'make installcheck' runs work

2015-05-14 Thread Stephen Frost
Make repeated 'make installcheck' runs work In pg_audit, set client_min_messages up to warning, then reset the role attributes, to completely reset the session while not making the regression tests depend on being run by any particular user. Branch -- master Details ---

Re: [COMMITTERS] pgsql: Fix portability issue in pg_audit.

2015-05-14 Thread Alvaro Herrera
Tom Lane wrote: Fix portability issue in pg_audit. %ld is not a portable way to print int64's. This may explain the buildfarm crashes we're seeing --- it seems to make dromedary happy, at least. FWIW you could use %zd for translatability, assuming we ever get pg_audit translatable. --

Re: [COMMITTERS] pgsql: Make repeated 'make installcheck' runs work

2015-05-14 Thread Stephen Frost
* Tom Lane (t...@sss.pgh.pa.us) wrote: Stephen Frost sfr...@snowman.net writes: Make repeated 'make installcheck' runs work Much better, thanks. BTW, isn't the pg_audit.conf file useless now? Yes, yes it is. Will remove. Thanks! Stephen signature.asc

Re: [COMMITTERS] pgsql: Add pg_audit, an auditing extension

2015-05-14 Thread Stephen Frost
* Stephen Frost (sfr...@snowman.net) wrote: I'll continue to think about it though, perhaps there's a way I can disable logging as the superuser without it logging the role involved. Of course, it occured to me how to address this immediately after, even though it hadn't in the hour or so

[COMMITTERS] pgsql: doc: list bigint as mapping to int8 and int64

2015-05-14 Thread Bruce Momjian
doc: list bigint as mapping to int8 and int64 Report by Paul Jungwirth Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/333a870f94ac23f29befa346324f9dab7f3265e9 Modified Files -- doc/src/sgml/xfunc.sgml |5 + 1 file changed, 5 insertions(+) --

[COMMITTERS] pgsql: Separate block sampling functions

2015-05-14 Thread Simon Riggs
Separate block sampling functions Refactoring ahead of tablesample patch Requested and reviewed by Michael Paquier Petr Jelinek Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/83e176ec18d2a91dbea1d0d1bd94c38dc47cd77c Modified Files --

[COMMITTERS] pgsql: Add pg_settings.pending_restart column

2015-05-14 Thread Peter Eisentraut
Add pg_settings.pending_restart column with input from David G. Johnston, Robert Haas, Michael Paquier Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/a486e35706eaea17e27e5fa0a2de6bc98546de1e Modified Files -- doc/src/sgml/catalogs.sgml |8

[COMMITTERS] pgsql: pg_upgrade: make controldata checks more consistent

2015-05-14 Thread Bruce Momjian
pg_upgrade: make controldata checks more consistent Also add missing float8_pass_by_value check. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/5a3022fde018aca9b23b7f7506233b437d943de2 Modified Files -- src/bin/pg_upgrade/controldata.c | 55

[COMMITTERS] pgsql: Teach UtfToLocal/LocalToUtf to support algorithmic encoding conv

2015-05-14 Thread Tom Lane
Teach UtfToLocal/LocalToUtf to support algorithmic encoding conversions. Until now, these functions have only supported encoding conversions using lookup tables, which is fine as long as there's not too many code points to convert. However, GB18030 expects all 1.1 million Unicode code points to

[COMMITTERS] pgsql: Honor traditional SGML NAMELEN limit.

2015-05-14 Thread Tom Lane
Honor traditional SGML NAMELEN limit. We've conformed to this limit in the past, so might as well continue to. Aaron Swenson Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/4b8f797f672bef07b4e87b4650b4035731b61d84 Modified Files --

Re: [COMMITTERS] pgsql: Separate block sampling functions

2015-05-14 Thread Tom Lane
Simon Riggs si...@2ndquadrant.com writes: Separate block sampling functions This patch broke buildfarm member crake. regards, tom lane -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription:

Re: [COMMITTERS] pgsql: Separate block sampling functions

2015-05-14 Thread Tom Lane
Michael Paquier michael.paqu...@gmail.com writes: On Fri, May 15, 2015 at 12:03 PM, Simon Riggs si...@2ndquadrant.com wrote: On 15 May 2015 at 03:50, Tom Lane t...@sss.pgh.pa.us wrote: Simon Riggs si...@2ndquadrant.com writes: Separate block sampling functions This patch broke buildfarm

Re: [COMMITTERS] pgsql: Separate block sampling functions

2015-05-14 Thread Simon Riggs
On 15 May 2015 at 03:50, Tom Lane t...@sss.pgh.pa.us wrote: Simon Riggs si...@2ndquadrant.com writes: Separate block sampling functions This patch broke buildfarm member crake. OK, thanks. I missed that amongst the other unrelated failures. Looking now. -- Simon Riggs

Re: [COMMITTERS] pgsql: Separate block sampling functions

2015-05-14 Thread Simon Riggs
On 15 May 2015 at 04:06, Michael Paquier michael.paqu...@gmail.com wrote: On Fri, May 15, 2015 at 12:03 PM, Simon Riggs si...@2ndquadrant.com wrote: On 15 May 2015 at 03:50, Tom Lane t...@sss.pgh.pa.us wrote: Simon Riggs si...@2ndquadrant.com writes: Separate block sampling functions

Re: [COMMITTERS] pgsql: Separate block sampling functions

2015-05-14 Thread Tom Lane
Michael Paquier michael.paqu...@gmail.com writes: On Fri, May 15, 2015 at 12:22 PM, Tom Lane t...@sss.pgh.pa.us wrote: TBH, I think that this patch itself was a bad idea and should be reverted. I don't object to changing APIs used by external modules when there's a good reason to break them,

Re: [COMMITTERS] pgsql: Separate block sampling functions

2015-05-14 Thread Michael Paquier
On Fri, May 15, 2015 at 12:03 PM, Simon Riggs si...@2ndquadrant.com wrote: On 15 May 2015 at 03:50, Tom Lane t...@sss.pgh.pa.us wrote: Simon Riggs si...@2ndquadrant.com writes: Separate block sampling functions This patch broke buildfarm member crake. OK, thanks. I missed that amongst

Re: [COMMITTERS] pgsql: Separate block sampling functions

2015-05-14 Thread Michael Paquier
On Fri, May 15, 2015 at 12:12 PM, Simon Riggs si...@2ndquadrant.com wrote: On 15 May 2015 at 04:06, Michael Paquier michael.paqu...@gmail.com wrote: On Fri, May 15, 2015 at 12:03 PM, Simon Riggs si...@2ndquadrant.com wrote: On 15 May 2015 at 03:50, Tom Lane t...@sss.pgh.pa.us wrote:

Re: [COMMITTERS] pgsql: Separate block sampling functions

2015-05-14 Thread Michael Paquier
On Fri, May 15, 2015 at 12:22 PM, Tom Lane t...@sss.pgh.pa.us wrote: Michael Paquier michael.paqu...@gmail.com writes: On Fri, May 15, 2015 at 12:03 PM, Simon Riggs si...@2ndquadrant.com wrote: On 15 May 2015 at 03:50, Tom Lane t...@sss.pgh.pa.us wrote: Simon Riggs si...@2ndquadrant.com