Re: [PATCHES] GIN improvements
От | Tom Lane |
---|---|
Тема | Re: [PATCHES] GIN improvements |
Дата | |
Msg-id | 16562.1216829136@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: [PATCHES] GIN improvements (Teodor Sigaev <teodor@sigaev.ru>) |
Список | pgsql-hackers |
I wrote: >> Yeah, I was going to complain about that next :-). Autovacuum isn't >> going to trigger as a result of INSERT operations; somehow we have >> to teach it what to do for GIN indexes. I remember we discussed this >> at PGCon but I don't think we decided exactly what to do... One simple idea is to call aminsertcleanup (probably renamed to something else like amanalyzehook) during ANALYZE. This seems a bit grotty, but it has the very attractive property that we don't need to give the autovacuum control logic any special knowledge about GIN indexes. Either inserts or updates will lead it to trigger either auto-ANALYZE or auto-VACUUM, and either way GIN gets a cleanup opportunity. A possible argument against this is that if we later fix things so that VACUUM and ANALYZE can happen concurrently on the same table, amanalyzehook could get called concurrently with ambulkdelete or other vacuum-support operations. So the AM author would have to take care to interlock that safely. But this doesn't seem like a big deal to me --- interlocks against regular inserts/updates are probably a harder problem anyway. Thoughts? regards, tom lane
В списке pgsql-hackers по дате отправления: