Skip to content

BREAKING: Migrate Vault Storage from Cloudflare KV to Cloudflare D1 (SQLite)

Choose a tag to compare

@shuaiplus shuaiplus released this 11 Feb 16:28
· 748 commits to main since this release

Release Notes

v0.2.0 - 2026-02-08

Changed

  • Database update: Migrated from Cloudflare KV to D1 (SQLite) for vault storage.
    • Better performance for batch queries and JOIN operations.
    • True relational database with foreign keys and indexes.
    • Easier to maintain schema.
  • All KV operations replaced with D1 SQL queries.
  • Rate limiting now uses D1 tables instead of KV.
  • Automatic cleanup for expired rate limit records.

Added

  • JWT_SECRET configuration guard for first-time setup:
    • If JWT_SECRET is missing / too short (<32) / still using the sample value, the setup page shows a bilingual warning page with step-by-step Cloudflare instructions.
    • Built-in random secret generator with refresh + copy.
  • Split the registration/setup HTML into a dedicated module to keep handlers smaller and easier to maintain.

发布说明

v0.2.0 - 2026-02-08

变更

  • 数据库更新:存储后端从 Cloudflare KV 迁移到 D1(SQLite)。
    • 批量查询和 JOIN 操作性能更好。
    • 真正的关系型数据库,支持外键和索引。
    • Schema 更易维护。
  • 所有 KV 操作替换为 D1 SQL 查询。
  • 限流功能现在使用 D1 表而非 KV。
  • 自动清理过期的限流记录。

新增

  • JWT_SECRET 初始化配置保护:
    • 当 JWT_SECRET 缺失 / 长度不足(<32)/ 仍为示例值时,访问初始化页会显示双语警告页面,并给出 Cloudflare 后台的步骤说明。
    • 内置随机密钥生成器(刷新 + 复制)。
  • 将注册/初始化页面的 HTML 拆分到独立模块,便于维护。