Re: new GUC var: autovacuum_process_all_tables - Mailing list pgsql-hackers

From Simon Riggs
Subject Re: new GUC var: autovacuum_process_all_tables
Date
Msg-id 1233868591.4500.579.camel@ebony.2ndQuadrant
Whole thread Raw
In response to new GUC var: autovacuum_process_all_tables  (Alvaro Herrera <alvherre@commandprompt.com>)
Responses Re: new GUC var: autovacuum_process_all_tables
List pgsql-hackers
On Thu, 2009-02-05 at 17:45 -0300, Alvaro Herrera wrote:

> Right now, when autovacuum is turned on we always assume it's supposed
> to process all tables except those that have autovacuum_enabled=false.
> 
> Now, sometimes it might make more sense to keep it enabled but have it
> only check for certain tables, and leave the majority of them disabled.
> For this we'd have a separate GUC parameter, as in $SUBJECT (I'm not
> wedded to the name), and have the user set autovacuum_enabled=true via
> reloptions to enable it.

I would prefer it if that behaviour was enabled by putting a special
entry into pg_autovacuum, e.g.

"ALL TABLES", autovacuum_enabled=false

I don't really want more GUCs for every nuance of AV behaviour.

If you do this we'd want it to be selectable by database and schema as
well. Perhaps by inserting the oid of the relevant database or schema?

e.g. if we want to turn off AV for database X, which has oid x

then we insert into pg_autovacuum(x, false, ....)

or to make the default no-autovacuum for all tables in all databases

insert into pg_autovacuum(0, false, ....)

It would be useful if all but the first two columns were nullable also,
to avoid having to specify -1.

-- Simon Riggs           www.2ndQuadrant.comPostgreSQL Training, Services and Support



pgsql-hackers by date:

Previous
From: "Joshua D. Drake"
Date:
Subject: Re: new GUC var: autovacuum_process_all_tables
Next
From: Tom Lane
Date:
Subject: Re: new GUC var: autovacuum_process_all_tables