refactor(db): migrate career profile aggregate

Transfer the canonical career profile, revision history, and six relational child collections to provider-aware migration ownership. Preserve legacy JSON, ordered child data, indexes, and cascade semantics.
This commit is contained in:
cesnimda
2026-08-30 21:54:54 +02:00
parent a906916acc
commit 90ca23de33
13 changed files with 404 additions and 355 deletions
+8 -2
View File
@@ -41,6 +41,9 @@ cohesive table groups. It does not attempt to delete the legacy reconciler whole
manual and AI-approved text plus source/action metadata.
- Added `20260830132000_AdoptInterviewPrepItemSchema` for durable interview-practice content,
retaining user and AI questions, answers, prepared state, source metadata, and ordering.
- Added `20260830133000_AdoptCareerProfileSchema` for the canonical profile, append-only history,
and all six ordered relational child types. Legacy JSON, Norwegian text, stable keys, and cascade
ownership are retained.
- Corrected the ownership runbook: new tables now default to migrations; the reconciler is legacy
compatibility code to retire one dependency group at a time.
@@ -81,14 +84,17 @@ migration.
- Representative user-authored and AI-generated interview-preparation items survive adoption,
downgrade, and re-upgrade with practice state intact; their ordering index and application cascade
remain effective.
- A populated Career Profile with history, long-tail JSON, Norwegian text, experience, education,
skills, projects, certifications, and languages survives adoption, downgrade, and re-upgrade; all
14 aggregate indexes and parent cascades remain effective.
- Generated MariaDB SQL contains the provider-correct `SystemEmailSettings` DDL.
- Full backend: 734/734 passed after the interview-preparation transfer.
- Full backend: 735/735 passed after the Career Profile aggregate transfer.
- Fresh application startup over a new disposable SQLite database applied
`20260830120000_AdoptSystemEmailSettingsSchema` and reached the healthy listening state.
## Remaining JT-019 work
Fifteen model tables remain startup-created: the Career Profile aggregate and Identity group.
Seven model tables remain startup-created: the ASP.NET Identity group.
with parent dependencies. Transfer them in small dependency-aware migrations with blank, populated,
retry and MariaDB runtime proof. Column/index repairs must remain until historical upgrade fixtures
prove each one redundant.