提交 b31c17f9 编写于 作者: D dongeforever

Load and recover for dledger commitlog

上级 77b252bd
...@@ -263,6 +263,8 @@ public class DLedgerCommitLog extends CommitLog { ...@@ -263,6 +263,8 @@ public class DLedgerCommitLog extends CommitLog {
@Override @Override
public void recoverAbnormally(long maxPhyOffsetOfConsumeQueue) { public void recoverAbnormally(long maxPhyOffsetOfConsumeQueue) {
dLedgerFileStore.load();
dLedgerFileStore.recover();
if (dLedgerFileList.getMappedFiles().isEmpty()) { if (dLedgerFileList.getMappedFiles().isEmpty()) {
super.recoverAbnormally(maxPhyOffsetOfConsumeQueue); super.recoverAbnormally(maxPhyOffsetOfConsumeQueue);
} }
...@@ -270,6 +272,8 @@ public class DLedgerCommitLog extends CommitLog { ...@@ -270,6 +272,8 @@ public class DLedgerCommitLog extends CommitLog {
@Override @Override
public void recoverNormally(long maxPhyOffsetOfConsumeQueue) { public void recoverNormally(long maxPhyOffsetOfConsumeQueue) {
dLedgerFileStore.load();
dLedgerFileStore.recover();
if (dLedgerFileList.getMappedFiles().isEmpty()) { if (dLedgerFileList.getMappedFiles().isEmpty()) {
super.recoverNormally(maxPhyOffsetOfConsumeQueue); super.recoverNormally(maxPhyOffsetOfConsumeQueue);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册