docs: section 5.1 states every partition key column is TEXT COLLATE "C", and tables created before v0.1.13 keep the database collation on pk

未关闭 适合新手
#1,412 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 3 天内回复

还没有人认领这个 Issue。

评估

难度
1/5
预计耗时
1 小时以内
新手友好度
78/100
Issue 类型
文档
描述清晰度
描述清楚
活跃度
活跃
技术栈
markdown, postgresql, rust

调研方向

需要修改的句子位于 docs/design/04-component-storage.md 第 5.1 节第 390 行。请阅读其正下方的 'Sort key storage' 条目,以及 crates/storage-postgres/src/data/ddl.rs 中的 TEXT_KEY,以统一限定条件的措辞。完成的标准是:关于分区键的句子说明只有从 v0.1.13 起创建的表才在 pk 上带有 COLLATE "C",并指向技术债务 C-11。

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

描述

docs/design/04-component-storage.md, section 5.1, "Partition key storage" (line 390 on main at 44cd43667): "Partition key values are always stored as TEXT COLLATE "C"."

Tables created before v0.1.13 keep the database collation on pk, as on every other text key column (technical debt C-11 in docs/technical-debt.md, and #641 for the migration). TEXT_KEY in crates/storage-postgres/src/data/ddl.rs says so in its comment: tables created before the constant existed keep the database collation on these columns.

The next bullet of the same section, "Sort key storage", already states that qualification for the sort key columns. The builders put COLLATE "C" on every string key predicate and ORDER BY. So results are byte-ordered on tables created before the columns carried the collation, and the indexes cannot serve the predicates there.

Proposed change: qualify the partition key sentence the same way. For example: "Partition key values are stored as TEXT COLLATE "C" on tables created from v0.1.13 on. Older tables keep the database collation on pk (technical debt C-11)."

主要语言
Rust
星标
517
派生
60
平均合并
3 天 21 小时
30 天内合并 PR
116

环境准备

从这里开始

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

ExtendDB/extenddb 的其他 Issue

查看 ExtendDB/extenddb 的全部 Issue

相似的 Issue

更多 Rust Issue

把新 issue 发到你的邮箱

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