Gokulakannan Somasundaram wrote:

Well, one of the principal arguments for having VACUUM at all is that it
off-loads required maintenance effort from foreground transaction code
paths.  I'm not really going to be in favor of solutions that put more
work into the transaction code paths (HOT already did more of that than
I would like :-().  OTOH, I agree that scanning the WAL log doesn't
really sound like something well-matched to this problem either.


Tom, Don't you like the idea of building some more structures around WAL,
like Asynchronous Materialized views. Indexes, if implemented as  stated,
would remove the HOT code in the path of the transaction(as you may know).
I am also slightly doubtful of the argument, that doing full-table scans and
full index scans for Vacuum is efficient. Can you please advise me on why we
should not use a read only operation on WAL log ?

I haven't been paying close attention to this thread, but there is a couple general issues with using the WAL for this kind of things. First of all, one extremely cool feature of PostgreSQL is that transaction size is not limited by WAL space, unlike on many other DBMSs. I think many of the proposed ideas of reading WAL would require us to keep all WAL available back to the beginning of the oldest running transaction.

Another issue is that reading WAL is inherently not very scalable. There's only one WAL for the whole cluster, and it needs to be read sequentially, so it can easily become a bottleneck on large systems.

--
  Heikki Linnakangas
  EnterpriseDB   http://www.enterprisedb.com

---------------------------(end of broadcast)---------------------------
TIP 7: You can help support the PostgreSQL project by donating at

               http://www.postgresql.org/about/donate

Reply via email to