Files
soul-yongping/开发文档/2、架构/数据库.md
2026-02-09 15:09:29 +08:00

23 lines
733 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 数据库Mycontent-book
## 1. 当前状态
当前版本没有数据库。
内容都以文件形式存储在 Git 仓库里:`external/Mycontent-book/book/`
## 2. 未来什么时候需要数据库
满足任意一条,就考虑上数据库(优先 MongoDB
- 用户系统(登录、权限)
- 评论、标注、段落级笔记
- 全文检索服务(需要更强的查询与索引)
- 多人协作后台(比 Git 更“业务化”的编辑流程)
## 3. 如果要上 MongoDB最小模型建议
- `chapters`:章节元信息(路径、标题、更新时间、摘要)
- `snippets`:素材片段与来源(对应 `1、soul 全部.txt` 的时间戳/段落)
- `notes`:编辑标注与写作计划