beobal commented on a change in pull request #1160:
URL: https://github.com/apache/cassandra/pull/1160#discussion_r696008838



##########
File path: 
src/java/org/apache/cassandra/service/reads/repair/AbstractReadRepair.java
##########
@@ -124,18 +129,28 @@ public void startRepair(DigestResolver<E, P> 
digestResolver, Consumer<PartitionI
     {
         getRepairMeter().mark();
 
+        /*
+         * When repaired data tracking is enabled, a digest will be created 
from data reads from repaired SSTables.
+         * The digests from each replica can then be compared on the 
coordinator to detect any divergence in their
+         * repaired datasets. In this context, an SSTable is considered 
repaired if it is marked repaired or has a 
+         * pending repair session which has been committed. In addition to the 
digest, a set of ids for any pending but 
+         * as yet uncommitted repair sessions is recorded and returned to the 
coordinator. This is to help reduce false 
+         * positives caused by compaction lagging which can leave sstables 
from committed sessions in the pending state
+         * for a time.
+         */
+        boolean trackRepairedStatus = 
DatabaseDescriptor.getRepairedDataTrackingForPartitionReadsEnabled();
+
         // Do a full data read to resolve the correct response (and repair 
node that need be)
-        DataResolver<E, P> resolver = new DataResolver<>(command, replicaPlan, 
this, queryStartNanoTime);
+        DataResolver<E, P> resolver = new DataResolver<>(command, replicaPlan, 
this, queryStartNanoTime, trackRepairedStatus);
         ReadCallback<E, P> readCallback = new ReadCallback<>(resolver, 
command, replicaPlan, queryStartNanoTime);
 
         digestRepair = new DigestRepair(resolver, readCallback, 
resultConsumer);
 
         // if enabled, request additional info about repaired data from any 
full replicas

Review comment:
       this comment is probably a little redundant now




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to