On Mon, Nov 21, 2022 at 03:07:25PM +0000, Simon Riggs wrote:
> Attached patch implements VACUUM (BACKGROUND).
>
> There are quite a few small details to consider; please read the docs
> and comments.
>
> There is a noticeable delay before the background vacuum starts.
You disallowed some combinations of unsupported options, but not others,
like FULL, PARALLEL, etc. They should either be supported or
prohibited.
+ /* use default values */
+ tab.at_params.log_min_duration = 0;
0 isn't the default ?
Maybe VERBOSE should mean to set min_duration=0, otherwise it should use
the default ?
You only handle one rel, but ExecVacuum() has a loop around rels.
+NOTICE: autovacuum of "vactst" has been requested, using the options specified
=> I don't think it's useful to say "using the options specified".
Should autovacuum de-duplicate requests ?
BRIN doesn't do that, but it's intended for append-only tables, so the
issue doesn't really come up.
Could add psql tab-completion.
Is it going to be confusing that the session's GUC variables won't be
transmitted to autovacuum ? For example, the freeze and costing
parameters.
--
Justin