Re: another autovacuum scheduling thread

Nathan Bossart <nathandbossart@gmail.com>

From: Nathan Bossart <nathandbossart@gmail.com>
To: Sami Imseih <samimseih@gmail.com>
Cc: Robert Haas <robertmhaas@gmail.com>, David Rowley <dgrowleyml@gmail.com>, Jeremy Schneider <schneider@ardentperf.com>, pgsql-hackers@postgresql.org
Date: 2025-10-31T20:12:47Z
Lists: pgsql-hackers

Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. Add rudimentary table prioritization to autovacuum.

  2. Trigger more frequent autovacuums with relallfrozen

  3. Harden nbtree page deletion.

  4. Check for interrupts inside the nbtree page deletion code.

On Thu, Oct 30, 2025 at 07:38:15PM -0500, Sami Imseih wrote:
> Here is my attempt to test the behavior with the new prioritization.

Thanks.

> The results above show what I expected: the batch tables receive higher
> priority, as seen from the averages of autovacuum and autoanalyze runs.
> This behavior is expected, but it may catch some users by surprise after
> an upgrade, since certain tables will now receive more attention than
> others. Longer tests might also show more bloat accumulating on heavily
> updated tables. In such cases, a user may need to adjust autovacuum
> settings on a per-table basis to restore the previous behavior.

Interesting.  From these results, it almost sounds as if we're further
amplifying the intended effect of commit 06eae9e.  That could be a good
thing.  Something else I'm curious about is datfrozenxid, i.e., whether
prioritization keeps the database (M)XID ages lower.

-- 
nathan