lizhanhui commented on code in PR #8600:
URL: https://github.com/apache/rocketmq/pull/8600#discussion_r1758839628
##########
store/src/main/java/org/apache/rocketmq/store/queue/RocksDBConsumeQueueStore.java:
##########
@@ -164,12 +166,12 @@ private boolean shutdownInner() {
@Override
public void putMessagePositionInfoWrapper(DispatchRequest request) throws
RocksDBException {
- if (request == null || this.bufferDRList.size() >= BATCH_SIZE) {
- putMessagePosition();
- }
if (request != null) {
this.bufferDRList.add(request);
}
+ if (request == null || !enableBatchWriteKvCq ||
this.bufferDRList.size() >= BATCH_SIZE) {
Review Comment:
Actually, batching here does NOT improve performance at all. Building
consume queue in RocksDB has WAL disabled with atomic flush feature on. Put KV
into RocksDB actually means insert into MemTable without incurring any IO.
Given that all ops are memory-only, batching here is not necessary at all.
--
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]