@Greptime: GreptimeDB 的扁平格式查询现在可以在任何列上预过滤——标签、字段、时间戳——而不仅仅是主键。而…
摘要
GreptimeDB 的扁平格式查询现在支持在任何列(标签、字段、时间戳)上预过滤,而不仅仅是主键,性能提升高达 4.5 倍。此外,mito2 存储引擎移除了其遗留扫描路径,清理了约 1800 行代码。
查看缓存全文
缓存时间: 2026/05/08 19:37
GreptimeDB 的 flat-format 查询现在可以预过滤任意列——标签、字段、时间戳——而不仅仅是主键。与此同时,mito2 移除了遗留的扫描路径,删除了大约 1800 行代码。
双周报第 82 期: https://t.co/VDgBsaboRB
OpenDAL 0.56 与 CLI 元数据命令 | Greptime 双周报 - 第 82 期
来源:https://greptime.com/blogs/2026-05-03-greptimedb-biweekly-report
摘要 (https://greptime.com/blogs/2026-05-03-greptimedb-biweekly-report#summary)
开发周期:2026-04-20 ~ 2026-05-03
以下是近期提交的亮点:
greptimeCLI 支持metadata put命令,可直接进行键值操作- Flat 格式查询在扫描数据文件前,可预过滤任意列
- 窗口函数查询能正确处理 TimeRange 精度和列别名
建议旧版本用户升级以获取这些修复和改进。
贡献者 (https://greptime.com/blogs/2026-05-03-greptimedb-biweekly-report#contributors)
过去两周,共有 14 位贡献者 合并了 43 个 PR。其中 5 位社区贡献者 贡献了 8 个 PR。欢迎新贡献者:@QuakeWang (https://github.com/QuakeWang)、@BootstrapperSBL (https://github.com/BootstrapperSBL)、@onepizzateam (https://github.com/onepizzateam)、@JoeS51 (https://github.com/JoeS51)!
感谢我们的社区贡献者:
- @QuakeWang (https://github.com/QuakeWang):db#8051 (https://github.com/GreptimeTeam/greptimedb/pull/8051)、db#8036 (https://github.com/GreptimeTeam/greptimedb/pull/8036)、db#8021 (https://github.com/GreptimeTeam/greptimedb/pull/8021)
- @BootstrapperSBL (https://github.com/BootstrapperSBL):db#8035 (https://github.com/GreptimeTeam/greptimedb/pull/8035)
- @JoeS51 (https://github.com/JoeS51):db#7994 (https://github.com/GreptimeTeam/greptimedb/pull/7994)
近期 PR 亮点 (https://greptime.com/blogs/2026-05-03-greptimedb-biweekly-report#highlights-of-recent-prs)
db#8003 (https://github.com/GreptimeTeam/greptimedb/pull/8003) chore: 将 opendal 更新至 0.56 rc2 (https://greptime.com/blogs/2026-05-03-greptimedb-biweekly-report#db-8003-chore-update-the-opendal-to-0-56-rc2)
GreptimeDB 的存储层现在使用 OpenDAL 0.56,替换了之前的版本。此依赖更新保持了相同的对象存储接口,同时引入了上游的 bug 修复和改进。
db#7982 (https://github.com/GreptimeTeam/greptimedb/pull/7982) refactor(mito2): 移除 PrimaryKey 变体 (https://greptime.com/blogs/2026-05-03-greptimedb-biweekly-report#db-7982-refactor-mito2-remove-primarykey-variants)
mito2 存储引擎移除了遗留的主键扫描路径,所有查询仅使用 flat 格式。此次清理从查询执行流水线中删除了大约 1800 行未使用的代码。
db#7989 (https://github.com/GreptimeTeam/greptimedb/pull/7989) feat(cli): 添加 metadata put 键和表命令 (https://greptime.com/blogs/2026-05-03-greptimedb-biweekly-report#db-7989-feat-cli-add-metadata-put-key-and-table-commands)
GreptimeDB CLI 现在支持通过 metadata put 命令写入元数据,可直接进行键值操作和特定表的更新。用户可通过 --value-stdin 管道输入 JSON 负载,更新表信息和路由,避免 shell 转义问题。
db#7972 (https://github.com/GreptimeTeam/greptimedb/pull/7972) feat: 支持 flat 格式中任意列的预过滤 (https://greptime.com/blogs/2026-05-03-greptimedb-biweekly-report#db-7972-feat-support-prefiltering-any-columns-in-flat-format)
此前,parquet 预过滤仅能通过编码键解码作用于主键列。现在预过滤支持所有列类型(标签、字段、时间戳),为简单谓词和复杂表达式(如 IN、BETWEEN)提供了专门的执行路径,在 TSBS cpu-max-all 查询上实现了 4.5 倍的性能提升。
db#8019 (https://github.com/GreptimeTeam/greptimedb/pull/8019) fix: 窗口排序精度 TimeRange 偏移一位 & 更好的别名跟踪 (https://greptime.com/blogs/2026-05-03-greptimedb-biweekly-report#db-8019-fix-window-sort-off-by-one-precision-timerange-better-alias-track)
窗口排序优化现在能识别别名和包装的时间索引表达式,例如 SELECT ts AS timestamp ... ORDER BY timestamp 和 SELECT to_timestamp_millis(ts) ... ORDER BY ts,因此这些查询会使用更快的窗口排序执行路径,而非回退到常规排序。还修复了分区边界处的精度转换问题,防止时间戳单位变化时发生错误的行切片。
Good First Issue (https://greptime.com/blogs/2026-05-03-greptimedb-biweekly-report#good-first-issue)
Issue#7755 (https://github.com/GreptimeTeam/greptimedb/issues/7755) 功能请求:为 S3 对象存储支持 EKS Pod Identity / ECS 容器凭证端点 (https://greptime.com/blogs/2026-05-03-greptimedb-biweekly-report#issue-7755-feature-request-support-eks-pod-identity-ecs-container-credentials-endpoint-for-s3-object-storage)
将 OpenDAL 依赖更新至包含 reqsign >=0.18.1 的版本,以支持 AWS 容器凭证端点,用于 EKS Pod Identity 和 ECS 任务角色。
- 关键词:存储、依赖
- 难度:简单
Issue#7987 (https://github.com/GreptimeTeam/greptimedb/issues/7987) feat: 添加 flow_statistics 系统表和 SHOW FLOW STATUS 命令,用于 flow 运行时可观测性 (https://greptime.com/blogs/2026-05-03-greptimedb-biweekly-report#issue-7987-feat-add-flow-statistics-system-table-and-show-flow-status-for-flow-runtime-observability)
添加一个名为 flow_statistics 的系统表和一个 SHOW FLOW STATUS SQL 命令,用于显示 flow 的运行时信息,如启动时间、运行时长、处理的数据量以及近期错误。
- 关键词:SQL、可观测性
- 难度:中等
相似文章
@thomasp85:我激动万分,终于可以揭开我们2026年所做工作的神秘面纱:请认识 ggsql!一个全新的扩展……
Posit 宣布推出 ggsql 的 alpha 版本。ggsql 是一种新的 SQL 语言扩展,将图形语法风格的数据可视化引入 SQL,兼容 Quarto、Jupyter notebooks、Positron 和 VS Code。用户可以使用受 ggplot2 启发的熟悉 SQL 语法,创建分层、结构化的可视化图表。
@PlanetScale:数据库太慢?本地挂载 NVMe 存储带来无上限 IOPS,把数据中心级性能搬进云端……
PlanetScale 推出基于本地 NVMe 存储的高性能云托管方案,为 Vitess 与 Postgres 提供无上限 IOPS 与横向扩展能力。
扩展PostgreSQL以支持8亿ChatGPT用户
OpenAI分享了扩展PostgreSQL以支持8亿ChatGPT用户及每秒数百万查询的技术见解,采用了单主架构搭配50个只读副本,同时通过分片和优化策略管理写入密集型工作负载带来的挑战。
Gemini API 中平衡成本与可靠性的新途径
Google 为 Gemini API 推出了 Flex 和 Priority 推理层,为开发者提供了对同步请求成本与可靠性的精细控制。Flex 可为对延迟不敏感的任务节省 50% 的成本,而 Priority 则可确保关键应用的高可靠性。
@ycombinator: Ardent (@ArdentAI) 让你在 TB 级规模下 <6秒 克隆任何 Postgres 数据库,让编码代理可以测试代码,工程团队可以快速上线而不用担心影响生产…
Ardent 是一款 Y Combinator 支持的工具,能在 TB 级规模下于 6 秒内克隆任何 PostgreSQL 数据库,让编码代理和开发者可以在接近生产环境的克隆副本上测试代码,而不会造成停机风险。该工具已被 Supermemory 和 Surface Labs 等公司采用。