feat(BA-6628): cascade fragment deletion from the allow list#12518
Draft
jopemachine wants to merge 3 commits into
Draft
feat(BA-6628): cascade fragment deletion from the allow list#12518jopemachine wants to merge 3 commits into
jopemachine wants to merge 3 commits into
Conversation
jopemachine
added a commit
that referenced
this pull request
Jul 3, 2026
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
15c3f60 to
c96d21f
Compare
This was referenced Jul 3, 2026
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
65f7b52 to
4602841
Compare
Co-authored-by: octodog <mu001@lablup.com>
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.
Summary
Ties fragments to their allow-list entry with a composite FK and lets deletion cascade (BEP-1052 review feedback):
ON DELETE CASCADE.app_config_fragments (config_name, scope_type)now referencesapp_config_allow_list, so purging an allow-list entry drops every fragment written under it — a revoked value disappears from the merge in the same statement, with no orphaned fragments to clean up separately.only_ifgates on fragment update/purge are provably dead and are removed (from the actions, service, repository, and db_source). The create gate stays — it surfaces the domain error (AppConfigFragmentWriteNotAllowed) instead of a raw FK violation.a560420476b6: deletes orphaned fragments (rows whose entry was already removed — the same outcome the cascade would have produced), then creates the FK. No new index is needed: the fragments' unique constraint already prefixes(config_name, scope_type). Upgrade/downgrade and the live cascade were verified against a local DB.📚 Stacked PRs
Part of the AppConfigFragment / AppConfig stack under BEP-1052 (epic BA-5781). Merge in order:
feat(BA-6552): app_config_fragments DB model and Alembic migrationfeat(BA-6553): repository layerrefactor(BA-6619): consolidate AppConfigScopeType into common.datarefactor(BA-6620): ExistsQuerier + AppConfigAllowList.existsfeat(BA-6554): AppConfigFragment service layerfeat(BA-6628): move fragment rank to the allow list with scope defaults(replaces feat(BA-6628): conditional-bulk repository primitives #12429)feat(BA-6628): expose allow-list rank on the v2 API surfacefeat(BA-6628): cascade fragment deletion from the allow list← you are herefeat(BA-6626): app_config_fragment bulk repository layerfeat(BA-6618): AppConfigFragment bulk CRUD service layerfeat(BA-6555): app_config service layer (merge engine)feat(BA-6556): AppConfig REST v2 API🤖 Generated with Claude Code
📚 Documentation preview 📚: https://sorna--12518.org.readthedocs.build/en/12518/
📚 Documentation preview 📚: https://sorna-ko--12518.org.readthedocs.build/ko/12518/