Read repair is a mechanism in Cassandra that uses regular read requests as an opportunity to sync up replicas. When there is a disagreement, the nodes with the older (or missing) information receive a copy of the updated information.
Unfortunately, this has negative effects on lookup and compaction performance. Both lookups and compactions rule out matches on SSTables by looking at the minimum write timestamp in an SSTable. Read repaired data uses the original write's timestamp, which means that most new tables still have few old repairs in them. As a result, those SSTables are considered potentially overlapping with older SSTables, which means that
- they are consulted in exact-match queries, to rule out tombstones.
- Tombstones newer than this minimum timestamp can not easily be collected (see T150811#2858783).
Disabling read repair would remove these out-of-order writes, which is expected to improve performance and tombstone collection.
Disadvantages
The main disadvantage of disabling read repair is that inconsistencies introduced as part of operational incidents longer than the hint time window (2 hours) are no longer gradually cleaned up as part of normal reads.
However, arguably relying on read repairs for actual sync-up is a poor choice in any case. After an outage longer than the hint window, only a full repair or bootstrap can reliably bring the entire dataset back in sync. That said, we have not been able to successfully complete a full Cassandra repair on the full RESTBase dataset, so read repairs can offer a small improvement over the status quo of no repairs at all.