Andres Freund d9e903f3cb logical decoding: Tell reorderbuffer about all xids.
Logical decoding's reorderbuffer keeps transactions in an LSN ordered
list for efficiency. To make that's efficiently possible upper-level
xids are forced to be logged before nested subtransaction xids.  That
only works though if these records are all looked at: Unfortunately we
didn't do so for e.g. row level locks, which are otherwise uninteresting
for logical decoding.

This could lead to errors like:
"ERROR: subxact logged without previous toplevel record".

It's not sufficient to just look at row locking records, the xid could
appear first due to a lot of other types of records (which will trigger
the transaction to be marked logged with MarkCurrentTransactionIdLoggedIfAny).
So invent infrastructure to tell reorderbuffer about xids seen, when
they'd otherwise not pass through reorderbuffer.c.

Reported-By: Jarred Ward
Bug: #13844
Discussion: 20160105033249.1087.66040@wrigleys.postgresql.org
Backpatch: 9.4, where logical decoding was added
2016-03-05 18:02:20 -08:00
..
2016-01-02 13:33:40 -05:00
2016-01-02 14:19:48 -05:00
2016-01-02 13:33:40 -05:00
2015-05-23 21:35:49 -04:00
2016-01-02 13:33:40 -05:00
2016-01-02 13:33:40 -05:00
2016-01-02 13:33:40 -05:00
2016-01-02 13:33:40 -05:00
2016-01-02 13:33:40 -05:00
2015-05-23 21:35:49 -04:00
2016-01-02 13:33:40 -05:00
2016-02-01 11:43:48 +01:00
2016-01-02 13:33:40 -05:00
2015-05-20 16:56:22 +03:00
2016-01-02 13:33:40 -05:00
2016-01-02 13:33:40 -05:00
2016-01-02 13:33:40 -05:00
2016-01-02 13:33:40 -05:00
2016-01-02 13:33:40 -05:00
2016-01-02 13:33:40 -05:00
2016-01-02 13:33:40 -05:00
2015-05-28 12:48:25 -04:00

The PostgreSQL contrib tree
---------------------------

This subtree contains porting tools, analysis utilities, and plug-in
features that are not part of the core PostgreSQL system, mainly
because they address a limited audience or are too experimental to be
part of the main source tree.  This does not preclude their
usefulness.

User documentation for each module appears in the main SGML
documentation.

When building from the source distribution, these modules are not
built automatically, unless you build the "world" target.  You can
also build and install them all by running "make all" and "make
install" in this directory; or to build and install just one selected
module, do the same in that module's subdirectory.

Some directories supply new user-defined functions, operators, or
types.  To make use of one of these modules, after you have installed
the code you need to register the new SQL objects in the database
system by executing a CREATE EXTENSION command.  In a fresh database,
you can simply do

    CREATE EXTENSION module_name;

See the PostgreSQL documentation for more information about this
procedure.