CodeChain-io / CodeChain-io/codechain

Executing term change block took too much time

未關閉
#1,993 2 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視
主要語言
Rust
星號
256
分支
50
PR 合併指標
30 天內沒有已合併 PR

描述

In the Corgi network, executing term change block took too much time.

I copied the log from a Corgi node. Blocks Verifier #1's log message. "Blocks Verifier #1" thread does not print any log between two add_balance log. The gap is more than a second.
```
#164574181 2020-08-26 14:00:03.561690513 UTC Blocks Verifier #1 TRACE state add_balance(0x263b…fcb1, 0): 1029374756
#164574181 2020-08-26 14:00:05.957492963 UTC Blocks Verifier #1 TRACE state add_balance(0x6850…65e1, 2160): 1050470102
```

We can find this situation very frequently in Corgi. About 10 times in a day. It appears only in the term closing blocks.

The reason is that CodeChain reads all header in DB generated in a term. It is about 1000 headers.

貢獻指南

開啟貢獻指南

研究方向

從用於結束 term 的區塊之 Blocks Verifier 路徑開始,追蹤 CodeChain 如何從資料庫讀取某個 term 的所有 header。重現或測量 Corgi 中兩筆 add_balance 日誌項目之間的間隔,然後驗證 term change block 的執行不再產生報告中所述的數秒延遲。

由索引模型根據 Issue 內容生成。

評估

技術堆疊
rust
領域
blockchain, performance
Issue 類型
缺陷
難度
4/5
預估耗時
3-5 天
活躍度
停滯
描述清晰度
基本清楚
新手友好度
35/100

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。