Re: [HACKERS] handling TOAST tables in autovacuum

2008-06-09 Thread Zdenek Kotala
Alvaro Herrera napsal(a): Hi, We've been making noises about dealing with TOAST tables as separate entities in autovacuum for some time now. So here's a proposal: Maybe dumb idea - whats about make a queue of toast pointers ready for vacuum and remove this toast items directly from toast tab

Re: [HACKERS] handling TOAST tables in autovacuum

2008-06-08 Thread Tom Lane
Alvaro Herrera <[EMAIL PROTECTED]> writes: > Euler Taveira de Oliveira wrote: >> And based on your proposal, it'll be needed to add reloptions to toast >> tables too. IMO, we should keep that code as simple as possible. > Sure, what's the problem with that? We only need to make sure that > ALTE

Re: [HACKERS] handling TOAST tables in autovacuum

2008-06-08 Thread Alvaro Herrera
Euler Taveira de Oliveira wrote: > FYI, I have a WIP patch to remove pg_autovacuum in favor of reloptions. Really? Please send it my way to review/apply as soon as you have it ready, independently of what we do with toast tables. > Let's keep it simple. Why not just adding a toast_enabled fla

Re: [HACKERS] handling TOAST tables in autovacuum

2008-06-08 Thread Euler Taveira de Oliveira
Alvaro Herrera wrote: We've been making noises about dealing with TOAST tables as separate entities in autovacuum for some time now. So here's a proposal: Let's keep it simple. Why not just adding a toast_enabled flag (disabled by default) in pg_autovacuum? If it's set then main and toast tab

Re: [HACKERS] handling TOAST tables in autovacuum

2008-06-08 Thread Tom Lane
Alvaro Herrera <[EMAIL PROTECTED]> writes: > The point here is that if the user disables autovac for the main table, > then it's expected that it is automagically disabled for the toast table > as well, for the usual case where they are disabling it because the > table is too big. Hmm, good point.

Re: [HACKERS] handling TOAST tables in autovacuum

2008-06-08 Thread Alvaro Herrera
Tom Lane wrote: > Alvaro Herrera <[EMAIL PROTECTED]> writes: > > The only change of some consideration is that we will need two passes > > over pg_class to get the list of relations to vacuum, instead of one as > > we do currently. The problem is that we first need to fetch the > > (heap relid, to

Re: [HACKERS] handling TOAST tables in autovacuum

2008-06-08 Thread Tom Lane
Alvaro Herrera <[EMAIL PROTECTED]> writes: > The only change of some consideration is that we will need two passes > over pg_class to get the list of relations to vacuum, instead of one as > we do currently. The problem is that we first need to fetch the > (heap relid, toast relid) mapping before

[HACKERS] handling TOAST tables in autovacuum

2008-06-08 Thread Alvaro Herrera
Hi, We've been making noises about dealing with TOAST tables as separate entities in autovacuum for some time now. So here's a proposal: Let's do it. That's about it :-) The only change of some consideration is that we will need two passes over pg_class to get the list of relations to vacuum,