Move resource checks to deployment reconciliation#9653
Conversation
…gic to prevent race conditions
|
@codex: review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a5a533a5e2
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if reflect.DeepEqual(desiredArgs, currentArgs) { | ||
| // No provisioning args changed. Run a drift-aware health check of the deployment's provisioner | ||
| // resources instead of reprovisioning. | ||
| err = s.CheckDeploymentInner(ctx, d) |
There was a problem hiding this comment.
Reprovision when annotations-only updates occur
When a project update only changes annotations (admin/projects.go marks oldProj.Annotations as deployment-impacting), the desired/current RuntimeArgs are equal, so this new branch calls CheckDeploymentInner instead of provisionRuntime. The Kubernetes check only triggers reprovision for version/template/org plan/custom domain drift (admin/provisioner/kubernetes/kubernetes.go), so templates that consume project annotations via DeploymentAnnotations keep the old rendered values even though UpdateDeploymentsForProject scheduled reconciliation; before this change provisionRuntime always reapplied them.
Useful? React with 👍 / 👎.
Move deployment resource checks into the deployment reconciliation logic to prevent race conditions.
Checklist: