lizhimins commented on code in PR #9256:
URL: https://github.com/apache/rocketmq/pull/9256#discussion_r2050342396
##########
store/src/main/java/org/apache/rocketmq/store/queue/ConsumeQueueStore.java:
##########
@@ -54,16 +55,33 @@
import static
org.apache.rocketmq.store.config.StorePathConfigHelper.getStorePathConsumeQueue;
public class ConsumeQueueStore extends AbstractConsumeQueueStore {
+ private final FlushConsumeQueueService flushConsumeQueueService;
+ private final CorrectLogicOffsetService correctLogicOffsetService;
+ private final CleanConsumeQueueService cleanConsumeQueueService;
+
+ private long dispatchFromPhyOffset;
+ private long dispatchFromStoreTimestamp;
public ConsumeQueueStore(DefaultMessageStore messageStore) {
super(messageStore);
+ this.flushConsumeQueueService = new FlushConsumeQueueService();
+ this.correctLogicOffsetService = new CorrectLogicOffsetService();
+ this.cleanConsumeQueueService = new CleanConsumeQueueService();
}
@Override
public void start() {
+ this.flushConsumeQueueService.start();
+
messageStore.getScheduledCleanQueueExecutorService().scheduleAtFixedRate(this::cleanQueueFilesPeriodically,
+ 1000 * 60, this.messageStoreConfig.getCleanResourceInterval(),
TimeUnit.MILLISECONDS);
log.info("Default ConsumeQueueStore start!");
}
+ private void cleanQueueFilesPeriodically() {
+ this.correctLogicOffsetService.run();
Review Comment:
start()
--
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]