aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/gist
diff options
context:
space:
mode:
authorRobert Haas <rhaas@postgresql.org>2017-01-20 15:55:45 -0500
committerRobert Haas <rhaas@postgresql.org>2017-01-20 15:55:45 -0500
commitc6a389792e08980e395055ac219303cf4357ba33 (patch)
tree032735da70a93820b9ce325329651aeaf83c831a /src/backend/access/gist
parent6546ffb35db78365d9f0011d75d16625e6040437 (diff)
downloadpostgresql-c6a389792e08980e395055ac219303cf4357ba33.tar.gz
postgresql-c6a389792e08980e395055ac219303cf4357ba33.zip
Avoid useless respawining the autovacuum launcher at high speed.
When (1) autovacuum = off and (2) there's at least one database with an XID age greater than autovacuum_freeze_max_age and (3) all tables in that database that need vacuuming are already being processed by a worker and (4) the autovacuum launcher is started, a kind of infinite loop occurs. The launcher starts a worker and immediately exits. The worker, finding no worker to do, immediately starts the launcher, supposedly so that the next database can be processed. But because datfrozenxid for that database hasn't been advanced yet, the new worker gets put right back into the same database as the old one, where it once again starts the launcher and exits. High-speed ping pong ensues. There are several possible ways to break the cycle; this seems like the safest one. Amit Khandekar (code) and Robert Haas (comments), reviewed by Álvaro Herrera. Discussion: http://postgr.es/m/CAJ3gD9eWejf72HKquKSzax0r+epS=nAbQKNnykkMA0E8c+rMDg@mail.gmail.com
Diffstat (limited to 'src/backend/access/gist')
0 files changed, 0 insertions, 0 deletions