Skip to content

feat(BA-6626): app_config_fragment bulk repository layer#12426

Draft
jopemachine wants to merge 1 commit into
feat/BA-6628-conditional-bulk-primitivesfrom
feat/BA-6626-app-config-fragment-bulk-repository
Draft

feat(BA-6626): app_config_fragment bulk repository layer#12426
jopemachine wants to merge 1 commit into
feat/BA-6628-conditional-bulk-primitivesfrom
feat/BA-6626-app-config-fragment-bulk-repository

Conversation

@jopemachine

@jopemachine jopemachine commented Jun 26, 2026

Copy link
Copy Markdown
Member

Summary

Repository-layer foundation for app_config_fragment bulk operations, split out of #12401 (BA-6618) to keep that PR reviewable. No API/service surface here — the service layer stacks on top.

  • Generic conditional-bulk primitives in repositories/base: ConditionalCreator / ConditionalUpdater / ConditionalPurger and BulkConditionalCreator / BulkConditionalUpdater / BulkConditionalPurger — a write spec paired with an only_if existence gate.
  • WriteOps.bulk_conditional_create_partial / _update_partial / _purge_partial — each item runs in its own savepoint for partial success: a rejected gate, a missing target, or a failed write is reported per-item (with its batch index) while the rest proceed.
  • Repository errors ConditionalWriteNotAllowed / ConditionalWriteTargetNotFound.
  • app_config_fragment repository: AppConfigFragmentCreatorSpec becomes a plain CreatorSpec with scope-based rank (public < domain < user); bulk_create / bulk_update / bulk_purge in db_source + repository; the AppConfigFragmentBulkWriteResult data type (succeeded + failed[index, message]).
  • Repository and ops-provider unit tests.

📚 Stacked PRs

Part of the AppConfigFragment / AppConfig stack under BEP-1052 (epic BA-5781). Merge in order:

  1. feat(BA-6552): add app_config_fragments DB model and Alembic migration #12306feat(BA-6552): app_config_fragments DB model and Alembic migration
  2. feat(BA-6553): add app_config_fragments repository layer #12307feat(BA-6553): repository layer
  3. refactor(BA-6619): consolidate AppConfigScopeType into common.data (single definition) #12403refactor(BA-6619): consolidate AppConfigScopeType into common.data
  4. refactor(BA-6620): ExistsQuerier ops primitive + AppConfigAllowList.exists #12405refactor(BA-6620): ExistsQuerier + AppConfigAllowList.exists
  5. feat(BA-6554): add app_config_fragment service layer #12358feat(BA-6554): AppConfigFragment service layer
  6. feat(BA-6628): conditional-bulk repository primitives #12429feat(BA-6628): conditional-bulk repository primitives
  7. 👉 feat(BA-6626): app_config_fragment bulk repository layer #12426feat(BA-6626): app_config_fragment bulk repository layer ← you are here
  8. feat(BA-6618): app_config_fragment bulk CRUD service layer #12401feat(BA-6618): AppConfigFragment bulk CRUD service layer
  9. feat(BA-6555): add app_config service layer #12359feat(BA-6555): app_config service layer
  10. feat(BA-6556): AppConfig REST v2 API (raw fragments and merged read/update) #12377feat(BA-6556): AppConfig REST v2 API

@github-actions github-actions Bot added size:XL 500~ LoC comp:manager Related to Manager component labels Jun 26, 2026
@jopemachine jopemachine force-pushed the feat/BA-6626-app-config-fragment-bulk-repository branch from cf41d87 to ffa35db Compare June 26, 2026 04:59
jopemachine added a commit that referenced this pull request Jun 26, 2026
Bulk create/update/purge for app_config_fragment at the service layer, on top of the
repository primitives in #12426 (BA-6626):

- Bulk actions carrying BulkConditional{Creator,Updater,Purger} payloads, service methods,
  and BulkActionProcessor wiring (per-entity RBAC extension point; no validator yet).
- Partial-success results (succeeded + failed[index, message]).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Comment thread tests/unit/manager/repositories/ops/test_provider.py Outdated
@jopemachine jopemachine force-pushed the feat/BA-6626-app-config-fragment-bulk-repository branch from ffa35db to bcc97bb Compare June 26, 2026 07:12
jopemachine added a commit that referenced this pull request Jun 26, 2026
Bulk create/update/purge for app_config_fragment at the service layer, on top of the
repository primitives in #12426 (BA-6626):

- Bulk actions carrying BulkConditional{Creator,Updater,Purger} payloads, service methods,
  and BulkActionProcessor wiring (per-entity RBAC extension point; no validator yet).
- Partial-success results (succeeded + failed[index, message]).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Comment thread changes/12426.misc.md
@jopemachine jopemachine force-pushed the feat/BA-6626-app-config-fragment-bulk-repository branch from bcc97bb to 846bc64 Compare June 26, 2026 07:26
@jopemachine jopemachine changed the title feat(BA-6626): app_config_fragment bulk repository layer & conditional-bulk primitives feat(BA-6626): app_config_fragment bulk repository layer Jun 26, 2026
@jopemachine jopemachine changed the base branch from main to feat/BA-6628-conditional-bulk-primitives June 26, 2026 07:26
@github-actions github-actions Bot added size:L 100~500 LoC and removed size:XL 500~ LoC labels Jun 26, 2026
jopemachine added a commit that referenced this pull request Jun 26, 2026
Bulk create/update/purge for app_config_fragment at the service layer, on top of the
repository primitives in #12426 (BA-6626):

- Bulk actions carrying BulkConditional{Creator,Updater,Purger} payloads, service methods,
  and BulkActionProcessor wiring (per-entity RBAC extension point; no validator yet).
- Partial-success results (succeeded + failed[index, message]).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@jopemachine jopemachine force-pushed the feat/BA-6628-conditional-bulk-primitives branch from 87bcc0c to c83c084 Compare June 26, 2026 07:37
@jopemachine jopemachine force-pushed the feat/BA-6626-app-config-fragment-bulk-repository branch from 846bc64 to ef67230 Compare June 26, 2026 07:37
jopemachine added a commit that referenced this pull request Jun 26, 2026
Bulk create/update/purge for app_config_fragment at the service layer, on top of the
repository primitives in #12426 (BA-6626):

- Bulk actions carrying BulkConditional{Creator,Updater,Purger} payloads, service methods,
  and BulkActionProcessor wiring (per-entity RBAC extension point; no validator yet).
- Partial-success results (succeeded + failed[index, message]).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@jopemachine jopemachine force-pushed the feat/BA-6628-conditional-bulk-primitives branch from c83c084 to 7cda3f9 Compare June 26, 2026 08:03
@jopemachine jopemachine force-pushed the feat/BA-6626-app-config-fragment-bulk-repository branch from ef67230 to f2316f2 Compare June 26, 2026 08:03
jopemachine added a commit that referenced this pull request Jun 26, 2026
Bulk create/update/purge for app_config_fragment at the service layer, on top of the
repository primitives in #12426 (BA-6626):

- Bulk actions carrying BulkConditional{Creator,Updater,Purger} payloads, service methods,
  and BulkActionProcessor wiring (per-entity RBAC extension point; no validator yet).
- Partial-success results (succeeded + failed[index, message]).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@jopemachine jopemachine force-pushed the feat/BA-6628-conditional-bulk-primitives branch from 7cda3f9 to 614eaf0 Compare June 26, 2026 08:12
@jopemachine jopemachine force-pushed the feat/BA-6626-app-config-fragment-bulk-repository branch from f2316f2 to 3462f91 Compare June 26, 2026 08:12
jopemachine added a commit that referenced this pull request Jun 26, 2026
Bulk create/update/purge for app_config_fragment at the service layer, on top of the
repository primitives in #12426 (BA-6626):

- Bulk actions carrying BulkConditional{Creator,Updater,Purger} payloads, service methods,
  and BulkActionProcessor wiring (per-entity RBAC extension point; no validator yet).
- Partial-success results (succeeded + failed[index, message]).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@jopemachine jopemachine force-pushed the feat/BA-6628-conditional-bulk-primitives branch from 614eaf0 to 6d69904 Compare June 26, 2026 09:09
@jopemachine jopemachine force-pushed the feat/BA-6626-app-config-fragment-bulk-repository branch from 3462f91 to 14f10a1 Compare June 26, 2026 09:10
jopemachine added a commit that referenced this pull request Jun 26, 2026
Bulk create/update/purge for app_config_fragment at the service layer, on top of the
repository primitives in #12426 (BA-6626):

- Bulk actions carrying BulkConditional{Creator,Updater,Purger} payloads, service methods,
  and BulkActionProcessor wiring (per-entity RBAC extension point; no validator yet).
- Partial-success results (succeeded + failed[index, message]).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@jopemachine jopemachine force-pushed the feat/BA-6628-conditional-bulk-primitives branch from 6d69904 to 47fa255 Compare June 26, 2026 09:27
@jopemachine jopemachine force-pushed the feat/BA-6626-app-config-fragment-bulk-repository branch from 14f10a1 to 542e10e Compare June 26, 2026 09:28
jopemachine added a commit that referenced this pull request Jun 26, 2026
Bulk create/update/purge for app_config_fragment at the service layer, on top of the
repository primitives in #12426 (BA-6626):

- Bulk actions carrying BulkConditional{Creator,Updater,Purger} payloads, service methods,
  and BulkActionProcessor wiring (per-entity RBAC extension point; no validator yet).
- Partial-success results (succeeded + failed[index, message]).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Build the app_config_fragment bulk repository on the conditional-bulk primitives (#12429):

- AppConfigFragmentCreatorSpec as a plain CreatorSpec with scope-based rank
  (public < domain < user).
- bulk_create / bulk_update / bulk_purge in db_source + repository, returning the
  AppConfigFragmentBulkWriteResult data type (succeeded + failed[index, message]) — partial
  success via the WriteOps.bulk_conditional_*_partial primitives.
- Single create rewritten to gate + plain create (no next-value); GatedWrite removed.
- Repository unit tests.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@jopemachine jopemachine force-pushed the feat/BA-6628-conditional-bulk-primitives branch from 47fa255 to 0b72350 Compare June 26, 2026 09:50
@jopemachine jopemachine force-pushed the feat/BA-6626-app-config-fragment-bulk-repository branch from 542e10e to 1166463 Compare June 26, 2026 09:52
jopemachine added a commit that referenced this pull request Jun 26, 2026
Bulk create/update/purge for app_config_fragment at the service layer, on top of the
repository primitives in #12426 (BA-6626):

- Bulk actions carrying BulkConditional{Creator,Updater,Purger} payloads, service methods,
  and BulkActionProcessor wiring (per-entity RBAC extension point; no validator yet).
- Partial-success results (succeeded + failed[index, message]).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp:manager Related to Manager component size:L 100~500 LoC

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant