6.1 KiB
6.1 KiB
Research: Governance Artifact Retargeting to ManagedEnvironment
Decision Summary
Decision 1: Treat 282 as a surface-ownership slice, not a schema slice
- Decision:
282will retarget existing governance artifact resources and drillthroughs to the workspace-first admin runtime. It will not reopentenant_idtomanaged_environment_idpersistence work. - Why: repo truth already shows
managed_environment_idplusworkspace_idon the relevant models, and the real remaining gap is surface registration, route ownership, and context resolution. - Evidence:
OperationRun,Finding,Policy,BackupSet,RestoreRun,EvidenceSnapshot,ReviewPack,TenantReview, andStoredReportalready persistmanaged_environment_id- many models use
DerivesWorkspaceIdFromTenantor equivalent workspace derivation seams
Decision 2: Scope the implementation around current resource families
- Decision: the primary implementation unit is the current environment-owned Filament resource families, not a generic artifact abstraction.
- Why: the route and admin-registration drift is expressed in concrete resources such as
FindingResource,PolicyResource,BackupSetResource,RestoreRunResource,EvidenceSnapshotResource,ReviewPackResource, andStoredReportResource. - Evidence:
- several resources still include admin-hide guards through
shouldRegisterNavigation()checks against theadminpanel - read-only artifact resources still use
ManagedEnvironment::current()or mixed fallback chains that imply tenant-panel ownership
- several resources still include admin-hide guards through
Decision 3: Reuse shared context and link seams
- Decision: reuse
ResolvesPanelTenantContext,InteractsWithTenantOwnedRecords,RelatedNavigationResolver,CanonicalNavigationContext, andOperationRunLinksinstead of creating a new route-helper layer. - Why: the repo already has one shared environment-resolution seam and one shared navigation contract; the drift is in how existing resources still call them under tenant-panel assumptions.
- Evidence:
ResolvesPanelTenantContextalready branches foradminversustenantpanelsOperationRunLinksalready owns canonical operations URLs
Decision 4: Keep artifact lifecycle and stored-report productization deferred
- Decision: defer lifecycle semantics to Spec
267and broader stored-report surface/productization work to Spec277. - Why: both packages already exist and would broaden
282beyond route ownership and context resolution. - Evidence:
specs/267-artifact-lifecycle-retention/spec.mdis alreadyReady for implementationspecs/277-stored-reports-surface/spec.mdis alreadyReady for implementation
Decision 5: Keep provider, RBAC, copy, and no-legacy follow-through deferred
- Decision: defer Specs
283through287unchanged. - Why:
282is already broad enough at the resource-surface layer. Capability registries, taxonomies, RBAC redesign, vocabulary cleanup, and global cutover quality gates belong to the later reserved slots.
Decision 6: Keep adjacent pages out of scope for 282
- Decision: pages such as
TenantDiagnostics,InventoryCoverage, andBaselineCompareLandingremain out of scope for282unless a later implementation produces a concrete, isolated follow-up need. - Why: repo truth shows these are adjacent seams, not part of the minimum route-ownership contract needed for the current governance artifact resource families.
Touched Resource Inventory
| Family | Representative resources | Current repo issue |
|---|---|---|
| Governance registers | InventoryItemResource, PolicyResource, PolicyVersionResource, FindingResource, FindingExceptionResource |
admin-hidden registration or environment-context drift |
| Recovery and backup | BackupScheduleResource, BackupSetResource, RestoreRunResource |
admin-hidden registration plus many related links and action URLs |
| Evidence and reporting | EvidenceSnapshotResource, TenantReviewResource, ReviewPackResource, StoredReportResource |
environment resolution still assumes tenant-panel truth in fallbacks |
Candidate Deviations From Raw Backlog Text
- The raw candidate reads like a model and route retarget combined. Repo truth shows the model retarget already happened in Spec
279. - The raw candidate mentions renaming review concepts and removing remaining
/admin/tlinks broadly. For282, this is narrowed to the touched governance artifact surface families only; broader copy cleanup remains Spec286. - The raw candidate's
operation_runsmove is already satisfied at the persistence layer;282only retargets artifact-origin links into the workspace-first operations routes reused from Spec280. - The raw candidate's
backup itemsnote remains nested under backup-set and restore-run surfaces and does not become a separate top-level route family in282.
Implementation Risks To Hold During Tasks Generation
- Do not widen into lifecycle or reporting semantics just because
ReviewPackResourceandStoredReportResourceare touched. - Do not create new route helpers or a generic artifact surface layer.
- Do not leave any touched family half-migrated, where list pages move but action URLs or related links still emit tenant-panel destinations.
Files Reviewed
.specify/memory/constitution.mddocs/product/spec-candidates.mddocs/product/roadmap.mdspecs/267-artifact-lifecycle-retention/spec.mdspecs/277-stored-reports-surface/spec.mdspecs/279-workspace-managed-environment-core/spec.mdspecs/280-workspace-tenancy-environment-routing/spec.mdspecs/281-provider-connection-scope/spec.mdapps/platform/app/Models/OperationRun.phpapps/platform/app/Filament/Concerns/ResolvesPanelTenantContext.phpapps/platform/app/Filament/Resources/FindingResource.phpapps/platform/app/Filament/Resources/EvidenceSnapshotResource.phpapps/platform/app/Filament/Resources/ReviewPackResource.phpapps/platform/app/Filament/Resources/StoredReportResource.php- repo-wide searches for admin-hide guards and environment-context helper usage in Filament resources and pages