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
Persist state in statusreconciler #15585
Persist state in statusreconciler #15585
Conversation
Hi @adshmh. Thanks for your PR. I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks amazing! Couple small comments
@@ -53,6 +54,15 @@ type options struct { | |||
|
|||
tokenBurst int | |||
tokensPerHour int | |||
|
|||
// The following are used for reading/writing to GCS. | |||
gcsCredentialsFile string |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are these two and their associated flags something that could be DRYed out into a struct and embedded in all the controllers that do something similar? (tide, deck, etc)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds great. Could I submit this change as a separate PR once this one is merged, as it will change multiple controllers?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@adshmh I think we forgot to expose this as a flag in the first place 🤦♂️
Perhaps we can fix that with the patch to share this code between components that mean to write to GCS?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for catching that. Yes, I will include that in the patch.
/ok-to-test |
Signed-off-by: Arash Deshmeh <adeshmeh@ca.ibm.com>
This change prevents config Agent from sending more than one notification to each of its subscribers upon calling Start. Signed-off-by: Arash Deshmeh <adeshmeh@ca.ibm.com>
Status-reconciler now saves the last known state, i.e. configuration, in the specified status file, which can reside on either a local filesystem or on GCS. Upon start, status-reconciler compares this last known configuration to the current configuration, thus reacting to changes it may not have otherwise observed. Signed-off-by: Arash Deshmeh <adeshmeh@ca.ibm.com>
a02aee0
to
2bd9505
Compare
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: adshmh, stevekuznetsov 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 |
status-reconciler
now saves the last known configuration at every sync and loads it at startup time. Fixes #13084