Re: Visibility map and freezing - Mailing list pgsql-hackers

From Heikki Linnakangas
Subject Re: Visibility map and freezing
Date
Msg-id 49490693.1010508@enterprisedb.com
Whole thread Raw
In response to Re: Visibility map and freezing  (Zdenek Kotala <Zdenek.Kotala@Sun.COM>)
List pgsql-hackers
Zdenek Kotala wrote:
> What's about add second bit which mark frozen page (all tuples have 
> freeze XID)? It should avoid full scan, but extend size of map.

First of all, we'd still have to make the decision of when to scan pages 
that need freezing, and when to only scan pages that have dead tuples.

Secondly, if it's just one bit, we'd have to freeze all tuples on the 
page to set the bit, which is a lot more aggressive than we do now.

Thirdly, those frozen bits would be critical, not just hints like the 
visibility map is right now. Corrupt frozen bits would lead to data 
loss. That means we'd have to solve the problem of how to make sure the 
bits are always cleared when tuples are updated on a page. That's not 
completely crash-proof at the moment, see comments in visibilitymap.c. 
Even if we did solve that, I'd rather live with a hints-only visibility 
map for one release, before we take the plunge and make it a critical 
part. Just in case...

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


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: visibility maps
Next
From: "Merlin Moncure"
Date:
Subject: Re: notification payloads