Skip to content

Add V88 migration: Publishing schema V2 restructure - #456

Merged
ddon merged 3 commits into
BeamLabEU:devfrom
mdon:dev
Mar 26, 2026
Merged

Add V88 migration: Publishing schema V2 restructure#456
ddon merged 3 commits into
BeamLabEU:devfrom
mdon:dev

Conversation

@mdon

@mdon mdon commented Mar 26, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Restructure publishing tables so posts become a minimal routing shell and versions become the source of truth for status and metadata
  • Add active_version_uuid and trashed_at to posts, published_at to versions, title_i18n/description_i18n to groups
  • Data migration populates new columns from existing data, then drops legacy post columns (status, published_at, primary_language, data, scheduled_at)
  • Fix index prefix for non-public schema support in down/1
  • Guard migrate_version_data against partial re-run when primary_language column already dropped

mdon and others added 3 commits March 26, 2026 23:40
Restructure publishing tables so posts become a minimal routing shell
and versions become the source of truth for status and metadata.

- Add active_version_uuid and trashed_at to posts
- Add published_at to versions
- Add title_i18n and description_i18n to groups (for future i18n)
- Drop legacy post columns: status, published_at, primary_language,
  data, scheduled_at
- Drop obsolete indexes, add new partial indexes
- Data migration: populate new columns from existing data before drops

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Add schema prefix to restored index names in down/1 for non-public schema support
- Guard migrate_version_data against partial re-run when primary_language column already dropped

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
PostgreSQL does not allow schema-qualified names (e.g. public.idx_name)
in CREATE INDEX statements. Indexes inherit the schema from the table
they reference. Matches the V59 convention used throughout the project.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@ddon
ddon merged commit e35abae into BeamLabEU:dev Mar 26, 2026
6 checks passed
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.

2 participants