[COMMITTERS] pgsql: Handle OID column inheritance correctly in ALTER TABLE ... INHER

2017-01-04 Thread Tom Lane
Handle OID column inheritance correctly in ALTER TABLE ... INHERIT. Inheritance operations must treat the OID column, if any, much like regular user columns. But MergeAttributesIntoExisting() neglected to do that, leading to weird results after a table with OIDs is associated to a parent with OID

[COMMITTERS] pgsql: Handle OID column inheritance correctly in ALTER TABLE ... INHER

2017-01-04 Thread Tom Lane
Handle OID column inheritance correctly in ALTER TABLE ... INHERIT. Inheritance operations must treat the OID column, if any, much like regular user columns. But MergeAttributesIntoExisting() neglected to do that, leading to weird results after a table with OIDs is associated to a parent with OID

[COMMITTERS] pgsql: Handle OID column inheritance correctly in ALTER TABLE ... INHER

2017-01-04 Thread Tom Lane
Handle OID column inheritance correctly in ALTER TABLE ... INHERIT. Inheritance operations must treat the OID column, if any, much like regular user columns. But MergeAttributesIntoExisting() neglected to do that, leading to weird results after a table with OIDs is associated to a parent with OID

[COMMITTERS] pgsql: Handle OID column inheritance correctly in ALTER TABLE ... INHER

2017-01-04 Thread Tom Lane
Handle OID column inheritance correctly in ALTER TABLE ... INHERIT. Inheritance operations must treat the OID column, if any, much like regular user columns. But MergeAttributesIntoExisting() neglected to do that, leading to weird results after a table with OIDs is associated to a parent with OID

[COMMITTERS] pgsql: Handle OID column inheritance correctly in ALTER TABLE ... INHER

2017-01-04 Thread Tom Lane
Handle OID column inheritance correctly in ALTER TABLE ... INHERIT. Inheritance operations must treat the OID column, if any, much like regular user columns. But MergeAttributesIntoExisting() neglected to do that, leading to weird results after a table with OIDs is associated to a parent with OID

[COMMITTERS] pgsql: Handle OID column inheritance correctly in ALTER TABLE ... INHER

2017-01-04 Thread Tom Lane
Handle OID column inheritance correctly in ALTER TABLE ... INHERIT. Inheritance operations must treat the OID column, if any, much like regular user columns. But MergeAttributesIntoExisting() neglected to do that, leading to weird results after a table with OIDs is associated to a parent with OID

[COMMITTERS] pgsql: Improve documentation of timestamp internal representation.

2017-01-04 Thread Robert Haas
Improve documentation of timestamp internal representation. Be more clear that we represent timestamps in microseconds when integer timestamps are used, and in fractional seconds when floating-point timestamps are used. Discussion: http://postgr.es/m/20161212135045.GB15488@e733.localdomain Repor

[COMMITTERS] pgsql: Assorted code improvements for table partitioning.

2017-01-04 Thread Robert Haas
Assorted code improvements for table partitioning. Michael Paquier, per Coverity. Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/3633b3f65686d3e74ab868e33bc25bec8bcdc7c6 Modified Files -- src/backend/catalog/heap.c | 4 src/backend/catalog/par

Re: [COMMITTERS] pgsql: Update copyright for 2017

2017-01-04 Thread David Fetter
On Wed, Jan 04, 2017 at 11:54:07AM -0800, David Fetter wrote: > On Wed, Jan 04, 2017 at 02:20:52PM -0500, Tom Lane wrote: > > David Fetter writes: > > >>> Actually, my takeaway from this was "don't ever use git reset on > > >>> the repo". > > > > > That's actually not tenable. If we ever find so

[COMMITTERS] pgsql: Remove unnecessary arguments from partitioning functions.

2017-01-04 Thread Robert Haas
Remove unnecessary arguments from partitioning functions. RelationGetPartitionQual() and generate_partition_qual() are always called with recurse = true, so we don't need an argument for that. Extracted by me from a larger patch by Amit Langote. Branch -- master Details --- http://git.p

Re: [COMMITTERS] pgsql: Update copyright for 2017

2017-01-04 Thread David Fetter
On Wed, Jan 04, 2017 at 02:20:52PM -0500, Tom Lane wrote: > David Fetter writes: > >>> Actually, my takeaway from this was "don't ever use git reset on > >>> the repo". > > > That's actually not tenable. If we ever find something in our > > repo that we don't have full rights to, especially if i

[COMMITTERS] pgsql: Fix reporting of constraint violations for table partitioning.

2017-01-04 Thread Robert Haas
Fix reporting of constraint violations for table partitioning. After a tuple is routed to a partition, it has been converted from the root table's row type to the partition's row type. ExecConstraints needs to report the failure using the original tuple and the parent's tuple descriptor rather th

Re: [COMMITTERS] pgsql: Update copyright for 2017

2017-01-04 Thread Tom Lane
David Fetter writes: >>> Actually, my takeaway from this was "don't ever use git reset on >>> the repo". > That's actually not tenable. If we ever find something in our repo > that we don't have full rights to, especially if it's something that > would put roadblocks in front of people who'd lik

[COMMITTERS] pgsql: Add new TAP tests for pg_recvlogical

2017-01-04 Thread Simon Riggs
Add new TAP tests for pg_recvlogical Craig Ringer, reviewed by Euler Taveira and Naoki Okano Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/3e353a7bc2dd6a9edfffe7e045c810b421f7ecc4 Modified Files -- src/bin/pg_basebackup/Makefile| 2 ++

[COMMITTERS] pgsql: Add pg_recvlogical —-endpos=LSN

2017-01-04 Thread Simon Riggs
Add pg_recvlogical —-endpos=LSN Allow pg_recvlogical to specify an ending LSN, complementing the existing -—startpos=LSN option. Craig Ringer, reviewed by Euler Taveira and Naoki Okano Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/7c030783a5bd07cadffc2a1018bc33119

Re: [COMMITTERS] pgsql: Update copyright for 2017

2017-01-04 Thread David Fetter
On Wed, Jan 04, 2017 at 04:08:20PM +0100, Magnus Hagander wrote: > On Wed, Jan 4, 2017 at 4:05 PM, Tom Lane wrote: > > Andres Freund writes: > > > On 2017-01-03 13:02:28 -0500, Bruce Momjian wrote: > > >> Yeah, I was doing parallel pulls of different branches in git > > >> via shell script, and i

[COMMITTERS] pgsql: Prefer int-wide pg_atomic_flag over char-wide when using gcc int

2017-01-04 Thread Tom Lane
Prefer int-wide pg_atomic_flag over char-wide when using gcc intrinsics. configure can only probe the existence of gcc intrinsics, not how well they're implemented, and unfortunately the answer is sometimes "badly". In particular we've found that multiple compilers fail to implement char-width __s

[COMMITTERS] pgsql: Prefer int-wide pg_atomic_flag over char-wide when using gcc int

2017-01-04 Thread Tom Lane
Prefer int-wide pg_atomic_flag over char-wide when using gcc intrinsics. configure can only probe the existence of gcc intrinsics, not how well they're implemented, and unfortunately the answer is sometimes "badly". In particular we've found that multiple compilers fail to implement char-width __s

[COMMITTERS] pgsql: Prefer int-wide pg_atomic_flag over char-wide when using gcc int

2017-01-04 Thread Tom Lane
Prefer int-wide pg_atomic_flag over char-wide when using gcc intrinsics. configure can only probe the existence of gcc intrinsics, not how well they're implemented, and unfortunately the answer is sometimes "badly". In particular we've found that multiple compilers fail to implement char-width __s

[COMMITTERS] pgsql: Move partition_tuple_slot out of EState.

2017-01-04 Thread Robert Haas
Move partition_tuple_slot out of EState. Commit 2ac3ef7a01df859c62d0a02333b646d65eaec5ff added a TupleTapleSlot for partition tuple slot to EState (es_partition_tuple_slot) but it's more logical to have it as part of ModifyTableState (mt_partition_tuple_slot) and CopyState (partition_tuple_slot).

[COMMITTERS] pgsql: Re-allow SSL passphrase prompt at server start, but not thereaft

2017-01-04 Thread Tom Lane
Re-allow SSL passphrase prompt at server start, but not thereafter. Leave OpenSSL's default passphrase collection callback in place during the first call of secure_initialize() in server startup. Although that doesn't work terribly well in daemon contexts, some people feel we should not break it

[COMMITTERS] pgsql: Update obsolete comments in lwlock.h.

2017-01-04 Thread Robert Haas
Update obsolete comments in lwlock.h. The typical size of an LWLock is now 16 bytes even on 64-bit platforms, and the size of slock_t is now irrelevant. But pg_atomic_uint32 can (perhaps surprisingly) still be larger than 4 bytes, so there's still some marginal point to allowing LWLOCK_MINIMAL_SI

[COMMITTERS] pgsql: Add 18 new recovery TAP tests

2017-01-04 Thread Simon Riggs
Add 18 new recovery TAP tests Add new tests for physical repl slots and hot standby feedback. Craig Ringer, reviewed by Aleksander Alekseev and Simon Riggs Branch -- master Details --- http://git.postgresql.org/pg/commitdiff/0813216cb416bf9173ddc7ff3cf495755d943743 Modified Files -

[COMMITTERS] pgsql: Allow PostgresNode.pm tests to wait for catchup

2017-01-04 Thread Simon Riggs
Allow PostgresNode.pm tests to wait for catchup Add methods to the core test framework PostgresNode.pm to allow us to test that standby nodes have caught up with the master, as well as basic LSN handling. Used in tests recovery/t/001_stream_rep.pl and recovery/t/004_timeline_switch.pl Craig Ring

Re: [COMMITTERS] pgsql: Update copyright for 2017

2017-01-04 Thread Stephen Frost
* Tom Lane (t...@sss.pgh.pa.us) wrote: > Andres Freund writes: > > On 2017-01-03 13:02:28 -0500, Bruce Momjian wrote: > >> Yeah, I was doing parallel pulls of different branches in git via shell > >> script, and it seems the size of this commit showed me that doesn't > >> work. Sorry. > > > Shou

Re: [COMMITTERS] pgsql: Update copyright for 2017

2017-01-04 Thread Magnus Hagander
On Wed, Jan 4, 2017 at 4:05 PM, Tom Lane wrote: > Andres Freund writes: > > On 2017-01-03 13:02:28 -0500, Bruce Momjian wrote: > >> Yeah, I was doing parallel pulls of different branches in git via shell > >> script, and it seems the size of this commit showed me that doesn't > >> work. Sorry.

Re: [COMMITTERS] pgsql: Update copyright for 2017

2017-01-04 Thread Tom Lane
Andres Freund writes: > On 2017-01-03 13:02:28 -0500, Bruce Momjian wrote: >> Yeah, I was doing parallel pulls of different branches in git via shell >> script, and it seems the size of this commit showed me that doesn't >> work. Sorry. > Shouldn't you check the results of something like this be

[COMMITTERS] pgsql: Better fix for sequence access in hot standby test

2017-01-04 Thread Peter Eisentraut
Better fix for sequence access in hot standby test The purpose of the test was to check access to the sequence relation on a hot standby, so change the test to read a different column from the sequence, instead of just reading the catalog. From: Andreas Karlsson Branch -- master Details --

[COMMITTERS] pgsql: Attempt to handle pending-delete files on Windows

2017-01-04 Thread Magnus Hagander
Attempt to handle pending-delete files on Windows These files are deleted but not yet gone from the filesystem. Operations on them will return ERROR_DELETE_PENDING. With this we start treating that as ENOENT, meaning files does not exist (which is the state it will soon reach). This should be saf

[COMMITTERS] pgsql: Make wal streaming the default mode for pg_basebackup

2017-01-04 Thread Magnus Hagander
Make wal streaming the default mode for pg_basebackup Since streaming is now supported for all output formats, make this the default as this is what most people want. To get the old behavior, the parameter -X none can be specified to turn it off. This also removes the parameter -x for fetch, now

Re: [COMMITTERS] pgsql: Update copyright for 2017

2017-01-04 Thread Andres Freund
On 2017-01-03 13:02:28 -0500, Bruce Momjian wrote: > Yeah, I was doing parallel pulls of different branches in git via shell > script, and it seems the size of this commit showed me that doesn't > work. Sorry. Shouldn't you check the results of something like this before pushing? Sorry for piling