You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@rocketmq.apache.org by GitBox <gi...@apache.org> on 2022/06/16 06:39:57 UTC

[GitHub] [rocketmq] tsunghanjacktsai commented on issue #4463: indexFile flush question

tsunghanjacktsai commented on issue #4463:
URL: https://github.com/apache/rocketmq/issues/4463#issuecomment-1157291336

   Hi @liuzongliang0202 ,
   
   This is a good question. There are two different types of recovery strategies in RocketMQ to deal with the normal and abnormal exit of the broker, respectively. This enables the consistency between the CommitLog and the ConsumeQueue/IndexFile.
   
   According to your problem, which would be determined as an abnormal exit since the broker is down while the dispatching task (handled by ReputMessageService) from CommitLog to IndexFile haven't been completed. An abnormal exit could be judged by whether the abort file created whenever the broker starts exists as it would be removed whenever the broker ends up normally.
   
   After the broker restarts, the loading process of DefaultMessageStore will discover the abort file and execute the corresponding recovery strategy. FYI, the recovery logic is inside the CommigLog#recoverAbnormally().
   
   Welcome to RocketMQ community BTW :-)


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

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