> once, for regular VACUUM I think you really have to call it within
> each bulkdelete operation.
Exactly what I did in last patch.
> There's probably no point in optimizing
> it away in VACUUM FULL either, since surely it'll be fast to call
> index_cleanup when there's nothing in the pending list?
Sure, with empty pending list insertcleanup will just lock/unlock metapage.
> 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...
So, may be we just move insertcleanup call to ginbulkdelete/ginvacuumcleanup
but leave aminsertcleanup field in pg_proc for a future.
> I've already made a number of changes to the patch; let me keep working
> on it and send it back to you later.
ok
--
Teodor Sigaev E-mail: teodor@sigaev.ru
WWW: http://www.sigaev.ru/