forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit3499df0
committed
Support disabling index bypassing by VACUUM.
Generalize the INDEX_CLEANUP VACUUM parameter (and the correspondingreloption): make it into a ternary style boolean parameter. It nowexposes a third option, "auto". The "auto" option (which is now thedefault) enables the "bypass index vacuuming" optimization added bycommit1e55e7d."VACUUM (INDEX_CLEANUP TRUE)" is redefined to once again make VACUUMsimply do any required index vacuuming, regardless of how few deadtuples are encountered during the first scan of the target heap relation(unless there are exactly zero). This gives users a way of opting outof the "bypass index vacuuming" optimization, if for whatever reasonthat proves necessary. It is also expected to be used by PostgreSQLdevelopers as a testing option from time to time."VACUUM (INDEX_CLEANUP FALSE)" does the same thing as it always has: itforcibly disables both index vacuuming and index cleanup. It's notexpected to be used much in PostgreSQL 14. The failsafe mechanism addedby commit1e55e7d addresses the same problem in a simpler way.INDEX_CLEANUP can now be thought of as a testing and compatibilityoption.Author: Peter Geoghegan <pg@bowt.ie>Reviewed-By: Masahiko Sawada <sawada.mshk@gmail.com>Reviewed-By: Justin Pryzby <pryzby@telsasoft.com>Discussion:https://postgr.es/m/CAH2-WznrBoCST4_Gxh_G9hA8NzGUbeBGnOUC8FcXcrhqsv6OHQ@mail.gmail.com1 parent0912698 commit3499df0
File tree
13 files changed
+313
-127
lines changed- doc/src/sgml/ref
- src
- backend
- access
- common
- heap
- commands
- postmaster
- bin
- psql
- scripts
- include
- commands
- utils
- test/regress
- expected
- sql
13 files changed
+313
-127
lines changedLines changed: 15 additions & 8 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1473 | 1473 |
| |
1474 | 1474 |
| |
1475 | 1475 |
| |
1476 |
| - | |
| 1476 | + | |
1477 | 1477 |
| |
1478 | 1478 |
| |
1479 | 1479 |
| |
1480 | 1480 |
| |
1481 | 1481 |
| |
1482 | 1482 |
| |
1483 |
| - | |
1484 |
| - | |
1485 |
| - | |
1486 |
| - | |
1487 |
| - | |
1488 |
| - | |
1489 |
| - | |
| 1483 | + | |
| 1484 | + | |
| 1485 | + | |
| 1486 | + | |
| 1487 | + | |
| 1488 | + | |
| 1489 | + | |
| 1490 | + | |
| 1491 | + | |
| 1492 | + | |
| 1493 | + | |
| 1494 | + | |
| 1495 | + | |
| 1496 | + | |
1490 | 1497 |
| |
1491 | 1498 |
| |
1492 | 1499 |
| |
|
Lines changed: 41 additions & 16 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
32 | 32 |
| |
33 | 33 |
| |
34 | 34 |
| |
35 |
| - | |
| 35 | + | |
36 | 36 |
| |
37 | 37 |
| |
38 | 38 |
| |
| |||
193 | 193 |
| |
194 | 194 |
| |
195 | 195 |
| |
196 |
| - | |
197 |
| - | |
198 |
| - | |
199 |
| - | |
200 |
| - | |
201 |
| - | |
202 |
| - | |
203 |
| - | |
204 |
| - | |
205 |
| - | |
206 |
| - | |
207 |
| - | |
208 |
| - | |
209 |
| - | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
210 | 235 |
| |
211 | 236 |
| |
212 | 237 |
| |
| |||
217 | 242 |
| |
218 | 243 |
| |
219 | 244 |
| |
220 |
| - | |
| 245 | + | |
221 | 246 |
| |
222 | 247 |
| |
223 | 248 |
| |
|
Lines changed: 15 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
244 | 244 |
| |
245 | 245 |
| |
246 | 246 |
| |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
247 | 262 |
| |
248 | 263 |
| |
249 | 264 |
| |
|
Lines changed: 26 additions & 9 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
140 | 140 |
| |
141 | 141 |
| |
142 | 142 |
| |
143 |
| - | |
144 |
| - | |
145 |
| - | |
146 |
| - | |
147 |
| - | |
148 |
| - | |
149 |
| - | |
150 |
| - | |
151 |
| - | |
152 | 143 |
| |
153 | 144 |
| |
154 | 145 |
| |
| |||
474 | 465 |
| |
475 | 466 |
| |
476 | 467 |
| |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
477 | 483 |
| |
478 | 484 |
| |
479 | 485 |
| |
| |||
494 | 500 |
| |
495 | 501 |
| |
496 | 502 |
| |
| 503 | + | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
497 | 514 |
| |
498 | 515 |
| |
499 | 516 |
| |
|
0 commit comments
Comments
(0)