Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Four [limits] keys are accepted and not read or enforced

未关闭
#538 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 2 天内回复

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
55/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
rust
领域
backend

调研方向

Start by tracing LimitsConfig and the named paths: crates/auth/src/policy/document.rs, crates/engine/src/create_table.rs, crates/core/src/validation/mod.rs, and crates/engine/src/describe_limits.rs. Follow the existing policy read/write paths and table creation and update validation to decide how each configured limit is handled. Done means each key either affects enforcement as described or is removed from LimitsConfig; the expected errors are specified in the issue.

由索引模型根据 Issue 内容生成。

描述

Four [limits] keys are accepted by the configuration loader and documented, and the server does not act on them.

  • max_policy_document_bytes (crates/core/src/limits/mod.rs) has no reader. The policy document size check is PolicyDocument::from_json, which calls from_json_with_size_limit(json, 6_144) with a literal (crates/auth/src/policy/document.rs:157); both callers use from_json. Changing the key changes nothing.
  • max_tables_per_account is read only by the console settings page. CreateTable (crates/engine/src/create_table.rs) does not count the account's tables, so the limit is never enforced.
  • per_table_max_rcu and per_table_max_wcu are read only by DescribeLimits (crates/engine/src/describe_limits.rs), which reports them. Provisioned throughput validation (crates/core/src/validation/mod.rs) checks that each value is at least 1 and has no upper bound, so CreateTable and UpdateTable accept any value.

The configuration reference (#537) now describes each key as it behaves. This issue is the other half: either wire the keys (pass max_policy_document_bytes into from_json_with_size_limit on the write and read paths; count tables in CreateTable; bound provisioned throughput in validation) or remove them from LimitsConfig so an operator cannot set a limit that does nothing. The service rejects a table count above the account quota with LimitExceededException and a provisioned value above the per-table maximum with ValidationException; the messages are measured before any enforcement is written.

Found while checking every configuration key against the code that reads it, for #494.

主要语言
Rust
星标
517
派生
60
平均合并
2 天 22 小时
30 天内合并 PR
25

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

ExtendDB/extenddb 的其他 Issue

查看 ExtendDB/extenddb 的全部 Issue

相似的 Issue

更多 Rust Issue

把新 issue 发到你的邮箱

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