Maxwell-Guo commented on code in PR #2777:
URL: https://github.com/apache/cassandra/pull/2777#discussion_r1354145646


##########
src/java/org/apache/cassandra/db/commitlog/CommitLogSegment.java:
##########
@@ -175,7 +177,10 @@ static long getNextId()
 
         try
         {
-            channel = FileChannel.open(logFile.toPath(), 
StandardOpenOption.WRITE, StandardOpenOption.READ, StandardOpenOption.CREATE);
+            if(commitLog.configuration.isDirectIOEnabled())
+                channel = FileChannel.open(logFile.toPath(), 
StandardOpenOption.WRITE, StandardOpenOption.READ, StandardOpenOption.CREATE, 
ExtendedOpenOption.DIRECT);

Review Comment:
   seems have not make an implementation for commitlog reader ?
   
   this patch only work for write path , right ?



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