3.2 WAL:明确 write-stopped 后 pending/aborted entry 生命周期 #2
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
背景
第 3.2 节规定 WAL write / fsync failure 后,失败 batch 不发布,sequence 不复用,引擎进入 write-stopped 状态。第 3.3 节规定 flush 只刷
sequence <= publishedSequence且非 aborted 的 entry。问题
文档尚未明确 write-stopped 后 pending / unpublished / aborted entry 的完整生命周期。
需要明确的问题包括:
风险
如果规则不明确,后续实现可能把失败写入错误刷入 SSTable,或错误推进 checkpoint / MANIFEST,导致恢复路径认为失败 batch 已经持久化。
建议
补充规则:
参考
docs/design.md:117WAL write failure 处理docs/design.md:119fsync unknown 处理docs/design.md:588Flush 过滤规则