Re: pg_autovacuum integration attempt #2 - Mailing list pgsql-patches

From Matthew T. O'Connor
Subject Re: pg_autovacuum integration attempt #2
Date
Msg-id 3431.67.83.181.26.1090005557.squirrel@67.83.181.26
Whole thread Raw
In response to Re: pg_autovacuum integration attempt #2  (Bruce Momjian <pgman@candle.pha.pa.us>)
Responses Re: pg_autovacuum integration attempt #2
Re: pg_autovacuum integration attempt #2
List pgsql-patches
I think it's ready to apply barring any feedback to the contrary.
Actually I do have a small improvement I will send in tomorrow (sorry
can't do it any sooner) that defaulted autovac_enabled to false, and makes
autovac fail more gracefully when the stats system is not enabled, but
that shouldn't stop you from applying this patch.

The thing I was trying to do was use the GUC hook function to make sure
that the required GUC variables are also set before GUC reports autovac as
enabled.  This seemed cleaner to me, but apparently it won't work since it
seems that autovac_enabled is read from GUC before the stats variables,
and there is no way to force the order in which they are read.  Am I
missing something?

Matthew


> Matthew, were are we on this patch?
>
> ---------------------------------------------------------------------------
>
> Matthew T. O'Connor wrote:
>> FYI, I am out of town from Friday 7/2 till Monday evening 7/5.  I
>> probably won't have email while I'm gone.  I will continue working on
>> this when I get back.
>>
>> Also, I have made a few minor tweaks since submitting this patch namely
>> changing autovac_enabled to default to false.  I am also trying to use a
>> GUC assign hook function to require pgstat_collect_tuplelevel = true
>> when autovac_enabled = true.  The problem I'm running into is that the
>> hook function seems to be getting called before the pgstat variables is
>> set, thus the hook complains even when pgstat_collect_tuplelevel is set
>> to true.  Is there someway to force the order in which variables are
>> read from GUC?
>>
>> Thanks,
>>
>> Matthew
>>
>>
>> On Tue, 2004-06-29 at 10:44, Matthew T. O'Connor wrote:
>> > I have make the changes suggested after I posted my last patch, I have
>> > also make several additional improvements.  it needs to be tested
>> more,
>> > but since the deadline is coming up so soon, I wanted to post an
>> update
>> > just to keep everyone abreast of what I'm doing. Please review and let
>> > me know what I need to change to get it applied to CVS.
>> >
>> > As before, this patch requires that pg_autovacuum.c and .h are moved
>> > from contrib to src/backend/postmaster and src/include/postmaster
>> > respectively. I have also attached the pg_autovacuum.h file that needs
>> > to be put in src/include/catelog/ for the new pg_autovacuum system
>> > table.
>> >
>> > I assume I will have to write the docs for this, but right now I'm
>> > focusing on the code, I get get the docs written after the feature
>> > freeze.
>> >
>> > Matthew O'Connor
>> >
>> >
>> >
>> >
>> > ______________________________________________________________________
>> > ---------------------------(end of
>> broadcast)---------------------------
>> > TIP 8: explain analyze is your friend
>>
>>
>> ---------------------------(end of broadcast)---------------------------
>> TIP 5: Have you checked our extensive FAQ?
>>
>>                http://www.postgresql.org/docs/faqs/FAQ.html
>>
>
> --
>   Bruce Momjian                        |  http://candle.pha.pa.us
>   pgman@candle.pha.pa.us               |  (610) 359-1001
>   +  If your life is a hard drive,     |  13 Roberts Road
>   +  Christ can be your backup.        |  Newtown Square, Pennsylvania
> 19073
>
> ---------------------------(end of broadcast)---------------------------
> TIP 8: explain analyze is your friend
>
>


pgsql-patches by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: plperl win32
Next
From: Bruce Momjian
Date:
Subject: Re: pg_autovacuum integration attempt #2