postgresql/src
Tom Lane bdc2e7a19a Propagate xactStartTimestamp and stmtStartTimestamp to parallel workers.
Previously, a worker process would establish values for these based on
its own start time.  In v10 and up, this can trivially be shown to cause
misbehavior of transaction_timestamp(), timestamp_in(), and related
functions which are (perhaps unwisely?) marked parallel-safe.  It seems
likely that other behaviors might diverge from what happens in the parent
as well.

It's not as trivial to demonstrate problems in 9.6 or 9.5, but I'm sure
it's still possible, so back-patch to all branches containing parallel
worker infrastructure.

In HEAD only, mark now() and statement_timestamp() as parallel-safe
(other affected functions already were).  While in theory we could
still squeeze that change into v11, it doesn't seem important enough
to force a last-minute catversion bump.

Konstantin Knizhnik, whacked around a bit by me

Discussion: https://postgr.es/m/6406dbd2-5d37-4cb6-6eb2-9c44172c7e7c@postgrespro.ru
2018-10-06 12:00:10 -04:00
..
backend Propagate xactStartTimestamp and stmtStartTimestamp to parallel workers. 2018-10-06 12:00:10 -04:00
bin Allow btree comparison functions to return INT_MIN. 2018-10-05 16:01:30 -04:00
common Adjust error message 2018-08-06 10:54:19 +02:00
fe_utils Fix lexing of standard multi-character operators in edge cases. 2018-08-23 21:35:49 +01:00
include Propagate xactStartTimestamp and stmtStartTimestamp to parallel workers. 2018-10-06 12:00:10 -04:00
interfaces Fix lexing of standard multi-character operators in edge cases. 2018-08-23 21:35:49 +01:00
makefiles Prevent accidental linking of system-supplied copies of libpq.so etc. 2018-07-09 17:23:31 -04:00
pl Make some fixes to allow building Postgres on macOS 10.14 ("Mojave"). 2018-09-25 13:23:29 -04:00
port Set snprintf.c's maximum number of NL arguments to be 31. 2018-10-02 12:41:28 -04:00
template Make some fixes to allow building Postgres on macOS 10.14 ("Mojave"). 2018-09-25 13:23:29 -04:00
test MAXALIGN the target address where we store flattened value. 2018-10-03 09:54:01 +05:30
timezone Update time zone data files to tzdata release 2018e. 2018-05-09 13:55:48 -04:00
tools pgtest: run clean, build, and check stages separately 2018-07-28 15:34:06 -04:00
tutorial Update copyright for 2016 2016-01-02 13:33:40 -05:00
.gitignore
bcc32.mak
DEVELOPERS
Makefile Install TAP test infrastructure so it's available for extension testing. 2016-09-23 15:50:00 -04:00
Makefile.global.in Make some fixes to allow building Postgres on macOS 10.14 ("Mojave"). 2018-09-25 13:23:29 -04:00
Makefile.shlib Prevent accidental linking of system-supplied copies of libpq.so etc. 2018-07-09 17:23:31 -04:00
nls-global.mk nls-global.mk: search build dir for source files, too 2016-06-07 18:55:18 -04:00
win32.mak