Conversation
This was referenced Sep 17, 2026
Contributor
|
This PR has a migration; here is the generated SQL for for --
-- Create index project_org_status_idx on field(s) organization, status of model project
--
CREATE INDEX CONCURRENTLY "project_org_status_idx" ON "sentry_project" ("organization_id", "status");
--
-- Create index team_org_status_idx on field(s) organization, status of model team
--
CREATE INDEX CONCURRENTLY "team_org_status_idx" ON "sentry_team" ("organization_id", "status"); |
Expose organization-scoped active project and team IDs without hydrating full resource models. Include teamless projects and preserve active-status filtering across silo modes. Refs ISWF-3361
shashjar
force-pushed
the
shashjar/iswf-3361-active-resource-ids
branch
from
September 17, 2026 23:02
0a3d8bd to
ce90fbd
Compare
Member
Author
|
We may want a separate follow-up migration adding Existing organization-leading indexes can support these lookups, and we have not established the incremental benefit of the composite indexes. Check representative query plans and timings first; if the benefit warrants it, add the indexes concurrently in a post-deployment migration. The index additions and migration have been removed from this PR. They are not a prerequisite for the hydration fix. |
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.
Add organization-routed RPCs that return only active project or team IDs. These provide the control silo with the resource sets needed for privileged access checks without loading and serializing every Project/Team model. Project IDs include projects without teams; both queries remain scoped to one organization and exclude inactive resources.
Deploy these RPCs to every cell before deploying the access-check consumer in PR 2. This PR has no model or schema changes.
Regression coverage exercises all silo modes, organization isolation, inactive resources, empty organizations, and RPC serialization.
Part 1 of 4 for ISWF-3361. Review/deploy order: 1: ID RPCs → 2: access checks → 3: broadcasts → 4: control defaults.