clarencen/lshift — Issue #76: Vacuuming large number diffs in a pair causes a full table scan
Author: clarencen
Created: 2011-11-14 22:41:36+00:00
State: open

When a pair is deleted, all of the associated diffs need to be removed as well. The statement

@@@
delete from diffs where pair = :1 and domain = :2
@@@

causes a full table scan (at least on Oracle).

Hence we should look into whether the table can either:

* Get indexed such that the deletion does not cause a scan;
* Get (portably) partitioned such that all diffs for a pair can be truncated.