Skip to content

chore(store): consolidate 009–014 into one 2026.06→2026.07 delta migration#465

Merged
PaulDotterer merged 1 commit into
mainfrom
chore/consolidate-migrations-2026.07
Jun 26, 2026
Merged

chore(store): consolidate 009–014 into one 2026.06→2026.07 delta migration#465
PaulDotterer merged 1 commit into
mainfrom
chore/consolidate-migrations-2026.07

Conversation

@PaulDotterer

Copy link
Copy Markdown
Contributor

What

Collapses the six incremental migrations that landed on main after the v2026.06 baseline (001008) into a single ordered 009_v2026_07.sql, so the 2026.06→2026.07 schema/data delta is one migration — matching the project's per-release migration convention (v2026.06 itself consolidated v2026.05's set).

Replaces:

was source
009_role_permission_split_7 #333
010_role_grant_scope_7 #334
011_events_append_only #404
012_idp_trust_email_assertions #412
013_luks_token_hash #420
014_reconciler_owned_role_permissions #440

Faithful, no schema change

Every statement is preserved verbatim, Up in original apply order, Down reversed, each +goose StatementBegin/End block intact. Each source migration's rationale comment is kept as a section header.

Verification:

  • sqlc generate → zero diff in internal/store/generated/ (consolidated schema is byte-identical).
  • seed_parity guard passes — migration 014's '{}' blanking stays the last statement to set system-role permissions, so the reconciler-owned invariant (WS17b feat: make agent release poll interval configurable #18) holds.
  • One +goose Up / one +goose Down; StatementBegin/End balanced.
  • The actual goose apply is exercised by the store-projectors CI shard (fresh Postgres, applies all migrations).

Note

Correct for the project's fresh-baseline-per-release model. Any persistent DB that already applied 009014 individually keeps orphan goose version rows 1014 (harmless — goose won't error, nothing re-applies). Fresh installs and CI template-clones are unaffected.

…ation

v2026.06 shipped migrations 001–008 as a clean baseline (itself a consolidation
of v2026.05's set). Six incremental migrations then landed on main for the
2026.07 cycle — 009 role-permission split (#333), 010 role-grant scope columns
(#334), 011 events append-only trigger (#404), 012 IdP trust_email_assertions
(#412), 013 LUKS token hashing (#420), 014 reconciler-owned system-role
permissions (#440). Per the project's per-release migration convention, collapse
them into a single ordered 009_v2026_07.sql so the 2026.06→2026.07 delta is one
migration.

Faithful concatenation: every statement preserved verbatim, Up in original apply
order, Down reversed, each StatementBegin/End block intact. No schema change —
`sqlc generate` produces an identical generated/ tree, and the seed-parity guard
(system-role permissions stay reconciler-owned) still passes.
@coderabbitai

coderabbitai Bot commented Jun 26, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@PaulDotterer, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 22 minutes and 50 seconds. Learn how PR review limits work.

Your organization has run out of usage credits. Purchase more credits in the billing tab to continue.

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based credits.

🚦 How do rate limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 3c7aef3c-6f85-4c6d-ae91-a1a44dff281b

📥 Commits

Reviewing files that changed from the base of the PR and between 11ae693 and e3b937b.

📒 Files selected for processing (7)
  • internal/store/migrations/009_role_permission_split_7.sql
  • internal/store/migrations/009_v2026_07.sql
  • internal/store/migrations/010_role_grant_scope_7.sql
  • internal/store/migrations/011_events_append_only.sql
  • internal/store/migrations/012_idp_trust_email_assertions.sql
  • internal/store/migrations/013_luks_token_hash.sql
  • internal/store/migrations/014_reconciler_owned_role_permissions.sql
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/consolidate-migrations-2026.07

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@PaulDotterer PaulDotterer merged commit f42b87f into main Jun 26, 2026
9 checks passed
@PaulDotterer PaulDotterer deleted the chore/consolidate-migrations-2026.07 branch June 27, 2026 15:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant