Mmuzaf commented on code in PR #2782:
URL: https://github.com/apache/cassandra/pull/2782#discussion_r1366120698


##########
src/java/org/apache/cassandra/index/sai/disk/io/IndexFileUtils.java:
##########
@@ -75,9 +79,20 @@ public IndexInput openBlockingInput(File file)
         return IndexInputReader.create(randomReader, fileHandle::close);
     }
 
+    public ChecksumIndexInput getBufferedChecksumIndexInput(IndexInput 
indexInput)
+    {
+        return new BufferedChecksumIndexInput(indexInput, 
CHECKSUM_FACTORY.get());
+    }
+
+    /**
+     * The SequentialWriter that calculates checksum of the data written to 
the file. This writer extends
+     * Cassandra's {@link SequentialWriter} to add the checksumming 
functionality and typically is used alongside

Review Comment:
   Fixed.



##########
src/java/org/apache/cassandra/index/sai/disk/io/IndexFileUtils.java:
##########
@@ -75,9 +79,20 @@ public IndexInput openBlockingInput(File file)
         return IndexInputReader.create(randomReader, fileHandle::close);
     }
 
+    public ChecksumIndexInput getBufferedChecksumIndexInput(IndexInput 
indexInput)
+    {
+        return new BufferedChecksumIndexInput(indexInput, 
CHECKSUM_FACTORY.get());
+    }
+
+    /**
+     * The SequentialWriter that calculates checksum of the data written to 
the file. This writer extends
+     * Cassandra's {@link SequentialWriter} to add the checksumming 
functionality and typically is used alongside
+     * with {@link IndexOutputWriter}. This, in turn, is used in conjunction 
with the {@link BufferedChecksumIndexInput}

Review Comment:
   Fixed.



##########
src/java/org/apache/cassandra/index/sai/disk/io/IndexFileUtils.java:
##########
@@ -75,9 +79,20 @@ public IndexInput openBlockingInput(File file)
         return IndexInputReader.create(randomReader, fileHandle::close);
     }
 
+    public ChecksumIndexInput getBufferedChecksumIndexInput(IndexInput 
indexInput)
+    {
+        return new BufferedChecksumIndexInput(indexInput, 
CHECKSUM_FACTORY.get());
+    }
+
+    /**
+     * The SequentialWriter that calculates checksum of the data written to 
the file. This writer extends
+     * Cassandra's {@link SequentialWriter} to add the checksumming 
functionality and typically is used alongside
+     * with {@link IndexOutputWriter}. This, in turn, is used in conjunction 
with the {@link BufferedChecksumIndexInput}
+     * to verify the checksum of the data read from the file, so that they 
must share the same checksum algorithm.

Review Comment:
   Fixed.



-- 
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