aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/gist/gistxlog.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2010-11-19 22:28:30 -0500
committerTom Lane <tgl@sss.pgh.pa.us>2010-11-19 22:28:30 -0500
commitfab2af30d6bb4ca893e2e9bf96863e6f1ce826d2 (patch)
tree2586868c9b22540422c0f84533ec746d27ae7220 /src/backend/access/gist/gistxlog.c
parent7ff02add837eb34354ca7197e521da3260aef9c1 (diff)
downloadpostgresql-fab2af30d6bb4ca893e2e9bf96863e6f1ce826d2.tar.gz
postgresql-fab2af30d6bb4ca893e2e9bf96863e6f1ce826d2.zip
Fix leakage of cost_limit when multiple autovacuum workers are active.
When using default autovacuum_vac_cost_limit, autovac_balance_cost relied on VacuumCostLimit to contain the correct global value ... but after the first time through in a particular worker process, it didn't, because we'd trashed it in previous iterations. Depending on the state of other autovac workers, this could result in a steady reduction of the effective cost_limit setting as a particular worker processed more and more tables, causing it to go slower and slower. Spotted by Simon Poole (bug #5759). Fix by saving and restoring the GUC variables in the loop in do_autovacuum. In passing, improve a few comments. Back-patch to 8.3 ... the cost rebalancing code has been buggy since it was put in.
Diffstat (limited to 'src/backend/access/gist/gistxlog.c')
0 files changed, 0 insertions, 0 deletions