Skip to content

Record workshop creation and invitation batch sends - #2854

Draft
mroderick wants to merge 2 commits into
feat/activity-admin-actionsfrom
feat/activity-workshops
Draft

Record workshop creation and invitation batch sends#2854
mroderick wants to merge 2 commits into
feat/activity-admin-actionsfrom
feat/activity-workshops

Conversation

@mroderick

@mroderick mroderick commented Sep 8, 2026

Copy link
Copy Markdown
Collaborator

Summary

Fifth of the activity-log stack (base: #2853). Records organiser creation work: workshop.created with a workshops.created_by_id stamp (migration + belongs_to :created_by), and invitation.send_batch for the InvitationLogger initiator.

Key changes

  • Creator is assigned via @workshop.created_by = current_user before save — atomic, no update_column, no validation-skipping disables.
  • Migration split into two: a transactional migration for column + FK (on_delete: :nullify), and a separate disable_ddl_transaction! migration for the concurrently-built index, so a failed index build cannot strand a half-applied migration.
  • Historical workshops keep created_by_id NULL (unknown); no backfill.

Review notes

The concurrent index is precautionary at current table size. Post-deploy check: SELECT COUNT(*) FROM workshops WHERE created_by_id IS NULL AND created_at > :deploy_time; should stay at 0.

Stack: PR 6 adds the admin activity strip UI.


Context and motivation: #2857

@mroderick
mroderick force-pushed the feat/activity-workshops branch from ee7782d to 47dec5f Compare September 9, 2026 10:11
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