1. 26 Mar, 2021 9 commits
  2. 25 Mar, 2021 12 commits
  3. 24 Mar, 2021 13 commits
  4. 23 Mar, 2021 6 commits
    • Tomas Vondra's avatar
      Allow composite types in catalog bootstrap · 79f6a942
      Tomas Vondra authored
      When resolving types during catalog bootstrap, try to reload the pg_type
      contents if a type is not found. That allows catalogs to contain
      composite types, e.g. row types for other catalogs.
      
      Author: Justin Pryzby
      Reviewed-by: Dean Rasheed, Tomas Vondra
      Discussion: https://postgr.es/m/ad7891d2-e90c-b446-9fe2-7419143847d7%40enterprisedb.com
      79f6a942
    • Tomas Vondra's avatar
      Convert Typ from array to list in bootstrap · e1a5e657
      Tomas Vondra authored
      It's a bit easier and more convenient to free and reload a List,
      compared to a plain array. This will be helpful when allowing catalogs
      to contain composite types.
      
      Author: Justin Pryzby
      Reviewed-by: Dean Rasheed, Tomas Vondra
      Discussion: https://postgr.es/m/ad7891d2-e90c-b446-9fe2-7419143847d7%40enterprisedb.com
      e1a5e657
    • Peter Geoghegan's avatar
      nbtree VACUUM: Cope with buggy opclasses. · 5b861baa
      Peter Geoghegan authored
      Teach nbtree VACUUM to press on with vacuuming in the event of a page
      deletion attempt that fails to "re-find" a downlink for its child/target
      page.
      
      There is no good reason to treat this as an irrecoverable error.  But
      there is a good reason not to: pressing on at this point removes any
      question of VACUUM not making progress solely due to misbehavior from
      user-defined operator class code.
      
      Discussion: https://postgr.es/m/CAH2-Wzma5G9CTtMjbrXTwOym+U=aWg-R7=-htySuztgoJLvZXg@mail.gmail.com
      5b861baa
    • Robert Haas's avatar
      Improve pg_amcheck's TAP test 003_check.pl. · 87d90ac6
      Robert Haas authored
      Disable autovacuum, because we don't want it to run against
      intentionally corrupted tables. Also, before corrupting the tables,
      run pg_amcheck and ensure that it passes. Otherwise, if something
      unexpected happens when we check the corrupted tables, it's not so
      clear whether it would have also happened before we corrupted
      them.
      
      Mark Dilger
      
      Discussion: http://postgr.es/m/AA5506CE-7D2A-42E4-A51D-358635E3722D@enterprisedb.com
      87d90ac6
    • Tom Lane's avatar
      Fix psql's \connect command some more. · ea801385
      Tom Lane authored
      Jasen Betts reported yet another unintended side effect of commit
      85c54287: reconnecting with "\c service=whatever" did not have the
      expected results.  The reason is that starting from the output of
      PQconndefaults() effectively allows environment variables (such
      as PGPORT) to override entries in the service file, whereas the
      normal priority is the other way around.
      
      Not using PQconndefaults at all would require yet a third main code
      path in do_connect's parameter setup, so I don't really want to fix
      it that way.  But we can have the logic effectively ignore all the
      default values for just a couple more lines of code.
      
      This patch doesn't change the behavior for "\c -reuse-previous=on
      service=whatever".  That remains significantly different from before
      85c54287, because many more parameters will be re-used, and thus
      not be possible for service entries to replace.  But I think this
      is (mostly?) intentional.  In any case, since libpq does not report
      where it got parameter values from, it's hard to do differently.
      
      Per bug #16936 from Jasen Betts.  As with the previous patches,
      back-patch to all supported branches.  (9.5 is unfortunately now
      out of support, so this won't get fixed there.)
      
      Discussion: https://postgr.es/m/16936-3f524322a53a29f0@postgresql.org
      ea801385
    • Tom Lane's avatar
      Avoid possible crash while finishing up a heap rewrite. · 9d523119
      Tom Lane authored
      end_heap_rewrite was not careful to ensure that the target relation
      is open at the smgr level before performing its final smgrimmedsync.
      In ordinary cases this is no problem, because it would have been
      opened earlier during the rewrite.  However a crash can be reproduced
      by re-clustering an empty table with CLOBBER_CACHE_ALWAYS enabled.
      
      Although that exact scenario does not crash in v13, I think that's
      a chance result of unrelated planner changes, and the problem is
      likely still reachable with other test cases.  The true proximate
      cause of this failure is commit c6b92041, which replaced a call to
      heap_sync (which was careful about opening smgr) with a direct call
      to smgrimmedsync.  Hence, back-patch to v13.
      
      Amul Sul, per report from Neha Sharma; cosmetic changes
      and test case by me.
      
      Discussion: https://postgr.es/m/CANiYTQsU7yMFpQYnv=BrcRVqK_3U3mtAzAsJCaqtzsDHfsUbdQ@mail.gmail.com
      9d523119