| From: | Kirk Wolak <wolakk(at)gmail(dot)com> |
|---|---|
| To: | Robert Haas <robertmhaas(at)gmail(dot)com> |
| Cc: | Salma El-Sayed <salmasayed182003(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org |
| Subject: | Re: [GSoC 2026] - B-tree Index Bloat Reduction - Approach & Questions |
| Date: | 2026-06-12 14:32:51 |
| Message-ID: | CACLU5mQp-bzxT6BMR3Dk8RM16bg-KGRAbm7nuHgiqA+rbqxF6Q@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Thu, Jun 11, 2026 at 3:19 PM Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
> On Fri, May 8, 2026 at 10:40 AM Salma El-Sayed
> ...
> > How should the merge process be triggered?
>
> This seems really tricky. I think if the user has to manually run a
> "try to merge pages" command or function, this functionality won't get
> used very much. Ideally it would happen either automatically during
> foreground operation, or as part of VACUUM. But that seems complicated
> to make work, because there's a risk of merging pages too
> aggressively, which could not only waste work but result in them being
> split again soon afterward.
>
Totally agree, Robert!
Our goal on this project is:
1) Provably Solve the problem with ONLY a function (on demand)
2) Teaching AutoVacuum to reset BTP_MERGED* back to normal, after XID as
you suggested.
3) Experiment with various levels of how much work each function call
performs (we are being very conservative)
But the final progress might be:
A) A core function for people to run/use (fine tune control over how
aggressive)
B) Integrated into AutoVacuum (when it sees/makes mostly empty pages, it
spits out a request to merge them, out of process)
C) Integrated into AutoVacuum (it actually applies the merge). This is
currently a step way too far away.
But that is likely going to be over full versions of PG (probably years,
not months).
Kirk
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Álvaro Herrera | 2026-06-12 14:44:21 | Re: Fix psql pager selection for wrapped expanded output |
| Previous Message | Tom Lane | 2026-06-12 14:22:37 | Re: Use \if/\endif to remove non-libxml2 expected output in regression tests |