graphprotocol / graphprotocol/graph-node
`BlockStore.chain_head_pointers` gets confused when the same chain is in multiple stores
还没有人认领这个 Issue。
- 主要语言
- Rust
- 星标
- 3.2k
- 派生
- 1.1k
- 平均合并
- 4 天 1 小时
- 30 天内合并 PR
- 1
描述
The method BlockStore.chain_head_pointers iterates over all shards slurping up information about chain head pointers without checking whether that data actually comes from the shard that is configured for any given chain. If a chain is present in more than one store (e.g., because it was moved to another shard) the information returned can be incorrect since old data might clobber new data.
The method needs to make sure that it only reads data from the correct shards. That's complicated a bit by the fact that we want to read all chain head pointers from a shard at once for performance, i.e. one query per shard, rather than one query per chain.
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
首先定位 BlockStore.chain_head_pointers,并阅读它如何跨多个 shard 收集 chain head pointer。跟踪每个 chain 的已配置 shard 是如何表示的,然后在某个 chain 存在于多个 store 中时验证结果;完成的标准是每个 shard 仍保留一个查询,同时过期数据无法覆盖已配置 shard 的数据。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- rust
- 领域
- databases, distributed-systems
- Issue 类型
- 缺陷
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 45/100