Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleanup issuer controller #42

Merged
merged 4 commits into from
Sep 6, 2023

Conversation

inteon
Copy link
Member

@inteon inteon commented Aug 15, 2023

I tried to make the issuer-controller logic a bit easier to read.

Additionally, this PR updates the Message in some of the Issuer conditions to match the event messages (eg. "Succeeded checking the issuer" instead of "checked").

@jetstack-bot jetstack-bot added dco-signoff: yes Indicates that all commits in the pull request have the valid DCO sign-off message. approved Indicates a PR has been approved by an approver from all required OWNERS files. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Aug 15, 2023
@inteon inteon force-pushed the cleanup_issuer_controller branch 3 times, most recently from ac07a05 to c0c5ea2 Compare August 15, 2023 17:27
Signed-off-by: Tim Ramlot <42113979+inteon@users.noreply.github.com>
fmt.Sprintf("Issuer is not ready yet: %s", err),
)
r.EventRecorder.Event(issuer, corev1.EventTypeWarning, eventIssuerRetryableError, message)
return result, issuerStatusPatch, err // apply patch, requeue with backoff
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can now directly return the error to trigger a reconciliation, because the other path returns an error too (using reconcile.TerminalError).

Signed-off-by: Tim Ramlot <42113979+inteon@users.noreply.github.com>
@jetstack-bot jetstack-bot removed the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 4, 2023
…nderstand

Signed-off-by: Tim Ramlot <42113979+inteon@users.noreply.github.com>
@inteon inteon requested a review from maelvls September 4, 2023 13:04
Co-authored-by: Maël Valais <mael@vls.dev>
Signed-off-by: Tim Ramlot <42113979+inteon@users.noreply.github.com>
@maelvls
Copy link
Member

maelvls commented Sep 6, 2023

Thanks for having addressed my comments. I think I’m good with the new changes.

/lgtm

@jetstack-bot jetstack-bot added the lgtm Indicates that a PR is ready to be merged. label Sep 6, 2023
@inteon
Copy link
Member Author

inteon commented Sep 6, 2023

/approve

@jetstack-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: inteon

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@jetstack-bot jetstack-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 6, 2023
@jetstack-bot jetstack-bot merged commit 32ad09f into cert-manager:main Sep 6, 2023
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. dco-signoff: yes Indicates that all commits in the pull request have the valid DCO sign-off message. lgtm Indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants