Escalate the 1.19 storage-flag deprecations: warn in 1.20, opt-in in 1.21, remove in 1.22
还没有人认领这个 Issue。
评估
- 难度
- 5/5
- 预计耗时
- 一周以上
- 新手友好度
- 38/100
- Issue 类型
- 重构
- 描述清晰度
- 基本清楚
- 活跃度
- 冷清
- 技术栈
- rust
- 领域
- api, documentation, release
调研方向
首先在 src/builders/ 中 grep Deprecated since 1.19.0,并检查这 18 个 setter 及其 build_inner 调用方。然后检查 release notes 文件和 CONTRIBUTING.md;在实现分阶段 checklist 之前,确定 since 的值以及对 BinaryQuantizationBuilder::new 的决定。完成意味着已覆盖选定的 release 阶段、测试和 -D warnings CI,并且已记录迁移指南和 1.22 的移除日期。
由索引模型根据 Issue 内容生成。
描述
Background
#288 (1.19 upgrade) supersedes the boolean storage flags with the new Memory enum and PayloadStorageParams:
on_disk→memoryalways_ram→memoryon_disk_payload→payload
Those 18 builder setters shipped in 1.19 carrying only a doc-comment note, not a #[deprecated] attribute. That was deliberate: #[deprecated] is a hard error for any downstream crate that builds with #![deny(warnings)] or -D warnings (as this repo's own CI does), so attaching it in 1.19 would have made the 1.18 → 1.19 bump source-breaking for ordinary builder-based code. Measured at the time by compiling the 1.18 release's own snippet suite against the branch: 18 errors with the attribute, 0 without.
The intent was always to escalate rather than leave them soft forever. This issue tracks that.
Constraint worth stating up front
A library cannot escalate the deprecated lint from warn to deny — that is the consumer's choice. So each rung below increases visibility and then withdraws the escape hatch; none of them turns the warning into an error from our side.
Schedule
| Release | Rung | Consumer impact |
|---|---|---|
| 1.19 ✅ | Doc-comment note pointing at the replacement | none |
| 1.20 | Add #[deprecated(since = "1.19.0", note = "…")] |
warning; error only for -D warnings builds |
| 1.21 | Move the setters behind an opt-in cargo feature, deprecated-api, default off |
hard break, recoverable with one line in Cargo.toml |
| 1.22 | Delete | hard break, no escape hatch |
Removal lands in 1.22. That should be stated in the 1.20 release notes, so the first warning a user sees already names the release that takes the methods away.
Inventory
18 setters, all in src/builders/:
on_disk → memory (12)
VectorParamsBuilder, VectorParamsDiffBuilder, HnswConfigDiffBuilder, SparseIndexConfigBuilder, KeywordIndexParamsBuilder, IntegerIndexParamsBuilder, FloatIndexParamsBuilder, BoolIndexParamsBuilder, GeoIndexParamsBuilder, DatetimeIndexParamsBuilder, UuidIndexParamsBuilder, TextIndexParamsBuilder
always_ram → memory (4)
ScalarQuantizationBuilder, ProductQuantizationBuilder, BinaryQuantizationBuilder, TurboQuantizationBuilder
on_disk_payload → payload (2)
CreateCollectionBuilder, CollectionParamsDiffBuilder
Each already carries a /// Deprecated since 1.19.0, use […](Self::…) instead. note, so the 1.20 change is mechanical — the sites are greppable with grep -rn "Deprecated since 1.19.0" src/builders/.
Loose end: BinaryQuantizationBuilder::new(always_ram: bool)
Its only parameter is the superseded flag. 1.19 added a Default impl so BinaryQuantizationBuilder::default().memory(..) works without it, but new itself still needs a decision by 1.22 — drop it, or change it to take no arguments (breaking either way).
Out of scope: generated proto fields
The 1.16-era deprecations (Vector::data / indices / vectors_count, same on VectorOutput) live in generated code and carry prost's #[deprecated] because the proto marks them [deprecated = true]. The client cannot retire those independently — that has to come from the server proto. Only the hand-written surface is ours to schedule.
Open question
since value. These became deprecated in 1.19 but the attribute lands in 1.20. since = "1.19.0" is semantically accurate and is what the table above assumes; since = "1.20.0" would instead match when users first see a warning. Minor either way.
Checklists
1.20
-
#[deprecated(since, note)]on all 18 setters -
#[allow(deprecated)]on the correspondingbuild_innerfns (they still populate the old proto fields) — already present from #288 - Repo's own usages migrated so CI stays green under
-D warnings - Migration table in the release notes, naming 1.22 as the removal release
-
CONTRIBUTING.mdrecords the ladder, so future upgrades follow it by default instead of re-deciding each time
1.21
-
deprecated-apifeature added, default off, gating the 18 setters - Release notes repeat the 1.22 removal date
1.22
- Setters deleted, feature removed
-
BinaryQuantizationBuilder::newresolved
- 主要语言
- Rust
- 星标
- 425
- 派生
- 89
- 平均合并
- 2 小时 48 分钟
- 30 天内合并 PR
- 3
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
qdrant/rust-client 的其他 Issue
-
难度 3/5 1-2 天 新手友好度 55/100
qdrant/rust-client#320 ·
-
upsert_points deep-clones the whole request on every call, not only on retry可能重新可做 @NullSense 于 7 天前认领,目前没有进行中的 PR。 未关闭
难度 4/5 3-5 天 新手友好度 35/100
qdrant/rust-client#316 · 3 条评论 ·
-
Option to set TLS domain name and :authority origin (client behind a tunnel/proxy)可能重新可做 @inamdarmihir 于 37 天前认领,目前没有进行中的 PR。 未关闭
难度 4/5 3-5 天 新手友好度 48/100
qdrant/rust-client#306 · 1 条评论 ·
-
难度 3/5 1-2 天 新手友好度 30/100
qdrant/rust-client#272 · 2 个 reaction ·
-
难度 4/5 3-5 天 新手友好度 25/100
qdrant/rust-client#267 · 1 条评论 · 2 个 reaction ·
查看 qdrant/rust-client 的全部 Issue
相似的 Issue
-
bug good first issue help wanted
难度 2/5 1-3 小时 新手友好度 78/100
getsotto/sotto-authenticator#139 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 82/100
维护者通常 2 天内回复
-
难度 2/5 1-3 小时 新手友好度 74/100
registrystack/registry-stack#2924 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
foundry-rs/starknet-foundry#4733 ·
维护者通常 4 天内回复
-
难度 1/5 1 小时以内 新手友好度 86/100