Re: Disabling vacuum truncate for autovacuum
Nathan Bossart <nathandbossart@gmail.com>
From: Nathan Bossart <nathandbossart@gmail.com>
To: Robert Haas <robertmhaas@gmail.com>
Cc: Laurenz Albe <laurenz.albe@cybertec.at>, Gurjeet Singh <gurjeet@singh.im>, Postgres Hackers <pgsql-hackers@postgresql.org>, Will Storey <will@summercat.com>
Date: 2025-02-18T19:56:09Z
Lists: pgsql-hackers, pgsql-general
On Mon, Jan 27, 2025 at 03:38:39PM -0500, Robert Haas wrote: > Also, how sure are we that turning this off globally is a solid idea? > Off-hand, it doesn't sound that bad: there are probably situations in > which autovacuum never truncates anything anyway just because the tail > blocks of the relations always contain at least 1 tuple. But we should > be careful not to add a setting that is far more likely to get people > into trouble than to get them out of it. It would be good to hear what > other people think about the risk vs. reward tradeoff in this case. My first reaction is that a global setting is probably fine most of the time. I'm sure it's possible to get into bad situations if you try hard enough, but that's not a unique characteristic. There are probably many situations where the truncation is wasted effort because we'll just end up extending the relation shortly afterwards, anyway. In any case, it's already possible to achieve $SUBJECT with a trivial script that sets storage parameters on all tables, so IMHO it would be silly to withhold a global setting that does the same thing just on principle. Of course, ideally we'd "fix" truncation on standbys, but that's at least v19 work at this point, and past discussion from many years ago [0] leads me to believe it's a difficult problem. That's not to say we should shy away from difficult problems... [0] https://postgr.es/m/flat/CAHGQGwE5UqFqSq1%3DkV3QtTUtXphTdyHA-8rAj4A%3DY%2Be4kyp3BQ%40mail.gmail.com -- nathan
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Expand comment for isset_offset.
- 7d559c8580f7 18.0 landed
-
Add vacuum_truncate configuration parameter.
- 0164a0f9ee12 18.0 landed