Preventing index scans for non-recoverable index AMs - Mailing list pgsql-hackers

From Simon Riggs
Subject Preventing index scans for non-recoverable index AMs
Date
Msg-id 1229549172.4793.105.camel@ebony.2ndQuadrant
Whole thread Raw
Responses Re: Preventing index scans for non-recoverable index AMs
Re: Preventing index scans for non-recoverable index AMs
List pgsql-hackers
Hot Standby won't work with hash indexes because they are
non-recoverable.

We have a number of ways of dealing with this:

1. Workaround: Implement WAL for hash indexes

2. Specific Solution: make hashcostestimate() massively increase cost of
scans during recovery so that they will very seldom be picked and make
hashbeginscan() refuse scans during recovery in case they do happen

3. Generic Solution: add amisrecoverable flag to pg_am, and alter
generic index AM to check whether index is recoverable before selecting
it during planning

I was hoping to do (1), but I'm looking for a quicker solution now so we
can tie up loose ends for review.

(2) seems most appropriate, since it will last only until (1) is
complete in a later release.

Anyone see additional options or prefer alternatives?

-- Simon Riggs           www.2ndQuadrant.comPostgreSQL Training, Services and Support



pgsql-hackers by date:

Previous
From: MUHAMMAD ASIF
Date:
Subject: Re: PLUGINS Functionlity in Win32 build scripts
Next
From: Simon Riggs
Date:
Subject: Re: Partitioning wiki page