0xMiden / 0xMiden/protocol

Introduce an account update size limit at the block level

未关闭
#1,770 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
kernels
主要语言
Rust
星标
132
派生
167
平均合并
1 天 23 小时
30 天内合并 PR
110

描述

As mentioned in https://github.com/0xMiden/miden-node/pull/1140#discussion_r2280650426, we should have a limit in place for account updates per block.

Notably, we already have `ACCOUNT_UPDATE_MAX_SIZE` which is $2^{18}$ currently (and will likely change again with https://github.com/0xMiden/miden-base/issues/1465), but it is only enforced on a transaction level. So with that limit set to 64 KiB, we essentially have a block limit of `ACCOUNT_UPDATE_MAX_SIZE * MAX_ACCOUNTS_PER_BLOCK` = 4 GiB, which is way too much.

The limit for this issue can either be per block globally or per account in a block. The former would allow a block to include a single large account update and many smaller ones, while the latter wouldn't but might be fairer overall.

Given that we already have `ACCOUNT_UPDATE_MAX_SIZE`, maybe a per block maximum might be the most flexible option.

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。