Skip to content

fix: requeue when NotAfter cannot be extracted (#114)#128

Merged
slauger merged 1 commit intomainfrom
fix/114-notafter-requeue
Mar 16, 2026
Merged

fix: requeue when NotAfter cannot be extracted (#114)#128
slauger merged 1 commit intomainfrom
fix/114-notafter-requeue

Conversation

@slauger
Copy link
Owner

@slauger slauger commented Mar 16, 2026

Summary

  • When the CA setup Job creates secrets via the Kubernetes API, the controller informer cache may not have synced yet
  • If NotAfter is nil after extraction, requeue after a short interval (5s) so it gets populated on the next reconcile
  • Applies to all three code paths: CertificateAuthority ready, Certificate adopted, and Certificate signed

Fixes #114

Test plan

  • go build ./... passes
  • go vet ./... passes
  • go test ./internal/controller/... passes
  • Deploy operator and verify NotAfter column shows valid dates after CA setup

When the CA setup Job creates secrets via the Kubernetes API, the
informer cache may not have synced yet. If NotAfter is nil after
extraction, requeue after a short interval so it gets populated on
the next reconcile.

Fixes #114
@slauger slauger merged commit a7a00ab into main Mar 16, 2026
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

NotAfter printer column shows invalid for Certificate and CertificateAuthority

1 participant