If we want to do this while keeping consistency, an option it to add set a configurable time barrier, to make impossible to send a put with an older timestamp than this barrier. This would be either a fixed one updated by the client, or a mobile one (ex: 15 minutes ago). This barrier could only be incremented.
- on a put, the region server would check than the put does not contain a timestamp older than the barrier.
This would allow:
- coupled with
HBASE-5930 (Periodically flush the Memstore), to do reads directly on the HFiles without compromising consistency;
- during recovery (or if recovery is slowed down because some blocks are corrupted) to continue to read, once the region is allocated again.
As a consequence, we would be able to continue to write and to read when there is a crash.
This is in the same area as
HBASE-2357, but simpler as we address only a subset of reads (the timeranged ones).