Skip to content

feat(plugin-security,plugin-sharing,platform-objects): ADR-0029 K2 security domain ownership + D7 nav#1445

Merged
os-zhuang merged 2 commits into
mainfrom
claude/adr-0029-k2-security-ownership
Jun 1, 2026
Merged

feat(plugin-security,plugin-sharing,platform-objects): ADR-0029 K2 security domain ownership + D7 nav#1445
os-zhuang merged 2 commits into
mainfrom
claude/adr-0029-k2-security-ownership

Conversation

@os-zhuang
Copy link
Copy Markdown
Contributor

Implements ADR-0029 K2 for the security domain — moves the security objects out of the platform-objects monolith into the two capability plugins that already register and operate them, split by concern (the two are orthogonal: sharing objects never reference RBAC objects).

Ownership split

Object New owner
sys_role, sys_permission_set, sys_user_permission_set, sys_role_permission_set + defaultPermissionSets seed @objectstack/plugin-security (RBAC; its bootstrap-platform-admin already consumes the seed)
sys_record_share, sys_sharing_rule, sys_share_link @objectstack/plugin-sharing
  • Definitions moved (git mv, history preserved) into each plugin's src/objects/; the RBAC + default-permission-set tests move with them into plugin-security.
  • platform-objects' /security subpath is now an empty barrel. Runtime is unchanged — both plugins already registered these objects at runtime; only the definitions' home moved. (Clean move, no facade: the dep direction would cycle and there are no external importers, as in K2.a/K2.b.)

D7 navigation

group_access_control is now assembled from three sources, preserving the original menu order:

  • plugin-security → Roles / Permission Sets (priority 100)
  • plugin-sharing → Sharing Rules / Record Shares (priority 200)
  • platform-objects base → API Keys only (sys_api_key is an identity object owned by plugin-auth; priority 300)

i18n (D8)

Removed from the platform-objects i18n extract config; existing generated bundles keep working at runtime (object-name keyed). Migrating extraction into the owning plugins remains the tracked follow-up.

Verification

Notes

  • plugin-security / plugin-sharing no longer import security objects from platform-objects in code; their package.json deps are left in place (consistent with prior K2 PRs).
  • After this, platform-objects/security is fully decomposed; audit/ (jobs/email/notifications) is intentionally untouched to avoid colliding with concurrent message-engine work.

https://claude.ai/code/session_01Tv6F1Ub6bhCedrx3r8sZM4


Generated by Claude Code

claude added 2 commits June 1, 2026 05:20
…curity domain ownership + D7 nav

Move the security objects out of the platform-objects monolith into the two
capability plugins that already register/operate them (orthogonal split — sharing
never references RBAC):

- plugin-security (RBAC): sys_role, sys_permission_set, sys_user_permission_set,
  sys_role_permission_set + defaultPermissionSets seed (consumed by
  bootstrap-platform-admin). RBAC/default-permission-set tests move with them.
- plugin-sharing: sys_record_share, sys_sharing_rule, sys_share_link.
- platform-objects /security subpath is now an empty barrel; runtime unchanged
  (both plugins already registered these at runtime).

D7: group_access_control is assembled from plugin-security (Roles/Permission
Sets, prio 100) + plugin-sharing (Sharing Rules/Record Shares, prio 200) +
platform-objects base (API Keys / sys_api_key identity object, prio 300),
preserving menu order.

D8: removed from the platform-objects i18n extract config; generated bundles keep
working. Plugin-side i18n extraction tracked as follow-up.

Tests: plugin-security 76 (incl. moved RBAC tests), plugin-sharing 54,
platform-objects 58 — green; turbo build (incl. DTS type-check) green.

https://claude.ai/code/session_01Tv6F1Ub6bhCedrx3r8sZM4
…curity-ownership

# Conflicts:
#	packages/platform-objects/src/apps/setup-nav.contributions.ts
@vercel
Copy link
Copy Markdown

vercel Bot commented Jun 1, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
spec Ready Ready Preview, Comment Jun 1, 2026 5:28am

Request Review

@github-actions github-actions Bot added documentation Improvements or additions to documentation tests tooling size/m labels Jun 1, 2026
@os-zhuang os-zhuang marked this pull request as ready for review June 1, 2026 05:32
@os-zhuang os-zhuang merged commit e478e0c into main Jun 1, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation size/m tests tooling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants