• Tom Lane's avatar
    Change the default value of max_prepared_transactions to zero, and add · 8d4f2ecd
    Tom Lane authored
    documentation warnings against setting it nonzero unless active use of
    prepared transactions is intended and a suitable transaction manager has been
    installed.  This should help to prevent the type of scenario we've seen
    several times now where a prepared transaction is forgotten and eventually
    causes severe maintenance problems (or even anti-wraparound shutdown).
    
    The only real reason we had the default be nonzero in the first place was to
    support regression testing of the feature.  To still be able to do that,
    tweak pg_regress to force a nonzero value during "make check".  Since we
    cannot force a nonzero value in "make installcheck", add a variant regression
    test "expected" file that shows the results that will be obtained when
    max_prepared_transactions is zero.
    
    Also, extend the HINT messages for transaction wraparound warnings to mention
    the possibility that old prepared transactions are causing the problem.
    
    All per today's discussion.
    8d4f2ecd
prepared_xacts_1.out 4.78 KB