Update claude db migration skill reference with additional constraints#2050
Update claude db migration skill reference with additional constraints#2050iplay88keys wants to merge 3 commits into
Conversation
Signed-off-by: Jeremy Alvis <jeremy.alvis@solo.io>
Signed-off-by: Jeremy Alvis <jeremy.alvis@solo.io>
There was a problem hiding this comment.
Pull request overview
Updates the kagent-dev database migrations reference to document stricter migration safety constraints (immutability, backward-compatibility window, and rollback/ahead-schema behavior) and to outline current vs. planned enforcement.
Changes:
- Expands the backward-compatibility guidance into a windowed “expand → deploy → contract” model with additional unsafe-change examples.
- Adds new guidance on linear migration history, ahead-schema tolerance, schema-agnostic SQL, and upgrade/rollback testing expectations.
- Extends the static-analysis enforcement section with additional (target) gates.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Signed-off-by: Jeremy Alvis <jeremy.alvis@solo.io>
|
step 3 says "re-runs the failed up migration" but rollbackToVersion only rolls back and then the process exits with an error. the re-run happens on the next startup, not in the same 1. might be worth correcting since the doc is being expanded anyway. |
|
1 more thing: it says "the core and vector migrations already comply" but the lint that would enforce this is marked as target/not yet enforced. how was compliance verified? |
What
Expands the migrations guide in the
kagent-devskill reference (.claude/skills/kagent-dev/references/database-migrations.md) to document the migration safety constraints.Changes
New sections:
mainmoved; a backward-compatible migration may ship in the same PR as its code.Reworked:
Major.Minor.Patch− 1 minor); destructive DDL must be declared and reviewed.Enforcement status
Gates that do not exist yet are marked Target — not yet enforced: the contraction guard, schema-agnostic lint, previous-minor round-trip and query-level tests, and the release-time patch/prefix checks. They document the intended gates; building them is follow-up work. The checks that exist today (
TestNoCrossTrackDDL,TestMigrationGuards, sqlc sync) are unchanged.