ref(seer-billing): Stop writing OrganizationContributors.integration_id and mark it pending deletion - #120767
Draft
srest2021 wants to merge 1 commit into
Draft
ref(seer-billing): Stop writing OrganizationContributors.integration_id and mark it pending deletion#120767srest2021 wants to merge 1 commit into
srest2021 wants to merge 1 commit into
Conversation
…id and mark it pending deletion Migrate OrganizationContributors uniqueness to (organization, provider, hostname, external_identifier) is complete, so integration_id is no longer read or written anywhere. This is the first of two deploys to drop the column safely per the column-deletion runbook. Stop writing integration_id (contributor_seats get_or_create defaults, the test factory), remove the field from the model, and add a deploy-time migration that drops the NOT NULL constraint and marks the field pending deletion (MOVE_TO_PENDING). A follow-up migration performs the physical drop. The getsentry provider backfill job -- the last remaining reader of the column -- is removed separately and must be in production first. Refs CW-1539 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Contributor
|
This PR has a migration; here is the generated SQL for for --
-- Alter field integration_id on organizationcontributors
--
ALTER TABLE "sentry_organizationcontributors" ALTER COLUMN "integration_id" DROP NOT NULL;
--
-- Moved organizationcontributors.integration_id field to pending deletion state
--
-- (no-op) |
Contributor
Backend Test FailuresFailures on
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Relates to CW-1539
Migration of OrganizationContributors uniqueness to (organization, provider, hostname, external_identifier) is complete, so integration_id is no longer read or written anywhere. This PR aims to drop the column safely per https://develop.sentry.dev/backend/application-domains/database-migrations/.
Stop writing integration_id, remove the field from the model, and add a deploy-time migration that drops the NOT NULL constraint and marks the field pending deletion (MOVE_TO_PENDING).
Followup PR to drop the column altogether: