Github user kevin-better commented on a diff in the pull request: https://github.com/apache/incubator-rocketmq/pull/150#discussion_r134944925 --- Diff: store/src/main/java/org/apache/rocketmq/store/DefaultMessageStore.java --- @@ -1094,34 +1090,15 @@ private boolean checkInDiskByCommitOffset(long offsetPy, long maxOffsetPy) { } private boolean isTheBatchFull(int sizePy, int maxMsgNums, int bufferTotal, int messageTotal, boolean isInDisk) { - - if (0 == bufferTotal || 0 == messageTotal) { - return false; - } - - if (maxMsgNums <= messageTotal) { - return true; - } - - if (isInDisk) { - if ((bufferTotal + sizePy) > this.messageStoreConfig.getMaxTransferBytesOnMessageInDisk()) { - return true; - } - - if (messageTotal > this.messageStoreConfig.getMaxTransferCountOnMessageInDisk() - 1) { - return true; - } - } else { - if ((bufferTotal + sizePy) > this.messageStoreConfig.getMaxTransferBytesOnMessageInMemory()) { - return true; - } - - if (messageTotal > this.messageStoreConfig.getMaxTransferCountOnMessageInMemory() - 1) { - return true; - } - } - - return false; + return (0 != bufferTotal && 0 != messageTotal) --- End diff -- ok , only alter function isOSPageCacheBusy
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---