Cassandra: destroy lists no catalog table before --yes, because Cassandra refuses the listing query

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

维护者通常 5 天内回复

还没有人认领这个 Issue。

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
78/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
cassandra, rust
领域
backend, databases

调研方向

从 crates/storage-cassandra/src/bootstrapper.rs 中约第 860 行的 list_table_names 开始,阅读目录查询的 Err(_) 处理逻辑。检查 Cassandra 4.1 如何处理不限制 partition key 的表列表查询,以及 extenddb destroy 如何生成确认前的输出。完成标准是提示中列出将被删除的目录表和 keyspace;使用相关测试或报告中的 Cassandra 4.1 配置进行验证。

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

描述

On Cassandra, what extenddb destroy prints before --yes lists no table of the catalog, whatever the catalog holds. It prints --- Tables in catalog: and then (none), so the operator confirms without a list of what goes.

list_table_names (crates/storage-cassandra/src/bootstrapper.rs:860 on main at 2ef56139e) sends SELECT table_name FROM <catalog>.tables ORDER BY table_name. Cassandra 4.1 refuses that query because it doesn't restrict the partition key. Its error is "ORDER BY is only supported when the partition key is restricted by an EQ or an IN." The Err(_) arm then returns an empty list, so the refusal never reaches the operator.

Measured with cqlsh on a table of the catalog's key shape, and with destroy without --yes from #1173's head on one cassandra:4.1 node, which printed (none). list_table_names is the same on main.

The keyspaces destroy drops are also printed only in the --yes run, so the prompt names none of them either.

主要语言
Rust
星标
517
派生
60
平均合并
4 天 23 小时
30 天内合并 PR
134

环境准备

从这里开始

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

ExtendDB/extenddb 的其他 Issue

查看 ExtendDB/extenddb 的全部 Issue

相似的 Issue

更多 Rust Issue

把新 issue 发到你的邮箱

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