Repository navigation
feat(delete): the remaining platform CronJobs and RBAC carry the PlatformInstance owner reference (#586 slice c) - #592
Merged
Conversation
…formInstance owner reference (D18, operator#589) Slice c of operator#586: ensure_pg_dumps, ensure_superset_rbac, ensure_superset_group_roles, ensure_airflow_rbac, ensure_airflow_group_roles, ensure_access_sync and ensure_identity take the owner reference and apply through apply_owned, so the garbage collector removes the access-sync CronJob, the Airflow/Superset RBAC objects, their group-role CronJobs, the pg-dump CronJobs and ConfigMap stardelt-identity with the instance.
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.
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.
Refs #589. Slice c of #586.
What changed
Seven functions in
crates/stardelt-operator/src/provision.rstakeowner: &OwnerReferenceand apply every object throughapply_owned(which stamps the owner reference before the server-side apply):ensure_pg_dumpsensure_superset_rbacensure_superset_group_rolesensure_airflow_rbacensure_airflow_group_rolesensure_access_syncensure_identitystardelt-identity(keeps itsdry_run: false)controller.rspasses&ownerat the seven call sites inreconcile_platform; 18 test call sites pass&owner(). One new test,the_access_sync_cron_job_carries_the_platform_instance_owner_reference.Deliberately untouched:
ensure_kafka_broker,ensure_trino_config_maps,ensure_trino_tls,ensure_catalog_principals, Secrets, PVCs, CNPG Clusters/ScheduledBackups.Checks
The ticket's
grep -c "apply_owned::<" => 21is advisory; measured onorigin/mainat08d29fait is 9 before and 28 after (9 + 19 new call sites). The binding check — noapply::<left in the seven functions — is 0.Mutation check: with
own(&mut object, owner)removed fromapply_owned, the new test fails (assertion left == right failedat thekindassert); restored.Remaining
Nothing in this slice.