mirror of
https://git.postgresql.org/git/postgresql.git
synced 2024-10-01 20:51:21 +02:00
Fix vacuum_cost_delay check for balance calculation.
Commit1021bd6a89
excluded autovacuum workers from cost-limit balance calculations when per-relation options were set. The code checks for limit and cost_delay being greater than zero, but since cost_delay can be set to -1 the test needs to check for greater than or zero. Backpatch to all supported branches since1021bd6a89
was backpatched all the way at the time. Author: Masahiko Sawada <sawada.mshk@gmail.com> Reviewed-by: Melanie Plageman <melanieplageman@gmail.com> Reviewed-by: Daniel Gustafsson <daniel@yesql.se> Discussion: https://postgr.es/m/CAD21AoBS7o6Ljt_vfqPQPf67AhzKu3fR0iqk8B=vVYczMugKMQ@mail.gmail.com Backpatch-through: v11 (all supported branches)
This commit is contained in:
parent
ee71cad9a7
commit
cba3c8f6dd
@ -2913,7 +2913,7 @@ table_recheck_autovac(Oid relid, HTAB *table_toast_map,
|
|||||||
*/
|
*/
|
||||||
tab->at_dobalance =
|
tab->at_dobalance =
|
||||||
!(avopts && (avopts->vacuum_cost_limit > 0 ||
|
!(avopts && (avopts->vacuum_cost_limit > 0 ||
|
||||||
avopts->vacuum_cost_delay > 0));
|
avopts->vacuum_cost_delay >= 0));
|
||||||
}
|
}
|
||||||
|
|
||||||
heap_freetuple(classTup);
|
heap_freetuple(classTup);
|
||||||
|
Loading…
Reference in New Issue
Block a user