0chain / 0chain/blobber

Minimum unit of data should be 64KB

未關閉
#936 0 則留言 0 個 reaction 已指派 1 人 已被 @lpoli 認領 在 GitHub 檢視
post-mainnet
主要語言
Go
星號
20
分支
26
PR 合併指標
30 天內沒有已合併 PR

描述

Since 0chain advocates minimum unit of data to be 64KB per file we need to correct price calculation for data stored in an allocation.
If `S` is size of data in writemarker and `W` is the write price then price calculation in storage smart contract should be:

`Price(p) = Ceil_of(S / 64KB) * 64KB * W`

However client can be clever to upload multiple files say, 1KB each and commit them with single writemarker. In this case if client had uploaded 64 such files then total size in writemarker is 64KB in which case above price calculation is not enough. Blobber however can decide whether to accept such writemarkers or not. In the above case, blobber should expect to get total size in writemarker to be 64 *64KB and if not then it should reject the writemarker.

This issue is an alias of https://github.com/0chain/gosdk/issues/451

貢獻指南

這個儲存庫沒有索引到貢獻指南

研究方向

該 issue 與儲存智能合約中資料分配的價格計算有關。查看 writemarker 的處理和價格計算邏輯,很可能在智能合約程式碼中。了解 blobber 如何驗證 writemarker。此變更涉及調整公式以使用 64KB 的最小單位,並可能新增 blobber 端驗證。查看關聯的 issue gosdk#451 以了解上下文。

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

評估

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

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

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