docs(adr): ADR-0009 schema migration story を draft する (#409)#416
Merged
Conversation
評価レポート REPORT_commercial_feasibility.md (PR #401) が「マイグレーション 機構の欠如」を **最大の実務懸念** と指摘。ADR-0005 が deferred とした migration story の trigger 条件 (外部視点 friction の明文化) が満たされた ため、ADR-0009 として整理。 ### Status: Accepted 3 options を比較: - A: 外付け Phinx / Liquibase - B: 版付き SchemaDefinition + auto-generated ALTER TABLE - C: cli/schemaDiff.php + operator-applied SQL (採用) 採用理由: NeNe philosophy (small framework / env-driven / operator-side concerns stay operator-side) と一致。ADR-0005 の single source を保つ (SchemaDefinition::buildTables() を直接読む)。destructive ops の責任を operator に明示 (rollback fantasy を約束しない)。Phinx を排除しない。 ### 初期 scope - Add column / Add table / Add index は ALTER TABLE 生成 - Drop column / Drop table / Drop index / type change / rename は CLI が warning を出すが SQL は出さない (operator 手書き) ### 実装 本 ADR は draft のみ。実装は次の trial / PR で個別。 ### Cross-link ADR-0005 Consequences の "Migrations are out of scope" 文に "addressed by ADR-0009" の cross-link を追加。 ADR README index に 0009 を追加。 Closes #409. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
評価レポート `REPORT_commercial_feasibility.md` (#401) が「マイグレーション機構の欠如」を 最大の実務懸念 と指摘 → ADR-0005 が deferred とした migration story の trigger 条件 (外部視点 friction 明文化) が満たされた。ADR-0009 として整理。
Decision: Option C 採用
3 options 比較:
採用は Option C。NeNe philosophy (small framework / env-driven / operator-side concerns stay operator-side) と一致。
Initial scope (実装は別 PR)
Cross-link
実装
本 PR は draft のみ。実装 (`cli/schemaDiff.php`) は次の trial / PR で。
Test plan
Closes #409.