- Notifications
You must be signed in to change notification settings - Fork5k
Commit720de00
committed
Fix fractional vacuum_cost_delay.
Commit4753ef3 changed vacuum_delay_point() to use the WaitLatch() API,to fix the problem that vacuum could keep running for a very long timeafter the postmaster died.Unfortunately, that broke commitcaf626b's support for fractionalvacuum_cost_delay, which shipped in PostgreSQL 12. WaitLatch() works inwhole milliseconds.For now, revert the change from commit4753ef3, but add an explicitcheck for postmaster death. That's an extra system call on systemsother than Linux and FreeBSD, but that overhead doesn't matter muchconsidering that we willingly went to sleep and woke up again. (Inlater work, we might add higher resolution timeouts to the latch API sothat we could do this with our standard programming pattern, but thatwouldn't be back-patched.)Back-patch to 14, where commit4753ef3 arrived.Reported-by: Melanie Plageman <melanieplageman@gmail.com>Discussion:https://postgr.es/m/CAAKRu_b-q0hXCBUCAATh0Z4Zi6UkiC0k2DFgoD3nC-r3SkR3tg%40mail.gmail.com1 parentd41a178 commit720de00
1 file changed
+13
-5
lines changedLines changed: 13 additions & 5 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
50 | 50 |
| |
51 | 51 |
| |
52 | 52 |
| |
| 53 | + | |
53 | 54 |
| |
54 | 55 |
| |
55 | 56 |
| |
| |||
2232 | 2233 |
| |
2233 | 2234 |
| |
2234 | 2235 |
| |
2235 |
| - | |
2236 |
| - | |
2237 |
| - | |
2238 |
| - | |
2239 |
| - | |
| 2236 | + | |
| 2237 | + | |
| 2238 | + | |
| 2239 | + | |
| 2240 | + | |
| 2241 | + | |
| 2242 | + | |
| 2243 | + | |
| 2244 | + | |
| 2245 | + | |
| 2246 | + | |
| 2247 | + | |
2240 | 2248 |
| |
2241 | 2249 |
| |
2242 | 2250 |
| |
|
0 commit comments
Comments
(0)