You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by "ShadowySpirits (via GitHub)" <gi...@apache.org> on 2023/05/04 10:23:21 UTC

[GitHub] [rocketmq] ShadowySpirits commented on a diff in pull request #6507: [ISSUE #6336] [RIP-62] Cold Read Control

ShadowySpirits commented on code in PR #6507:
URL: https://github.com/apache/rocketmq/pull/6507#discussion_r1184829418


##########
store/src/main/java/org/apache/rocketmq/store/util/LibC.java:
##########
@@ -50,4 +52,8 @@ public interface LibC extends Library {
     int mlockall(int flags);
 
     int msync(Pointer p, NativeLong length, int flags);
+
+    int mincore(Pointer p, NativeLong length, byte[] vec);

Review Comment:
   We do not need to introduce mincore with JNI but use `MappedByteBuffer#isLoaded0` instead. Please see `DefaultMessageStore#checkInMemByCommitOffset` for example.



-- 
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: commits-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org