-
Notifications
You must be signed in to change notification settings - Fork 226
Add only_set_unchanged_fields config to UpdateOperationConfig #621
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
Add only_set_unchanged_fields config to UpdateOperationConfig #621
Conversation
new config field is used in this mq-controller PR to apply delta check to setting of spec fields based on update operation response |
require.NotNil(crd) | ||
|
||
expected := ` | ||
if delta.DifferentAt("Spec.AuthenticationStrategy") { |
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.
is this lambda comparing the latest after a ReadOne from AWS with desired from K8s? At first glance i don't think so
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 is the delta passed to sdkUpdate
. So, it should be the a comparison of the desired and latest.
/test eks-controller-test |
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.
👍
- Add config field only_set_unchanged_fields to UpdateOperationConfig. - Add CRD.OnlySetChangedFieldsOnUpdate() func to check if only_set_unchanged_fields value - Add logic in SetResource to add delta.DifferentAt() checks when only_set_unchanged_fields is set. - Create unit test to verify new SetResource() behavior
6f57596
to
2104960
Compare
/retest |
1 similar comment
/retest |
/test ecr-controller-test |
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 @knottnt !
/test ecr-controller-test |
/hold |
/unhold |
/test s3-controller-test |
/test eks-controller-test |
/test ec2-controller-test |
/test eks-controller-test |
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.
/lgtm
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: a-hilaly, knottnt 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 |
/retest |
@knottnt: The following tests failed, say
Full PR test history. Your PR dashboard. 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. I understand the commands that are listed here. |
/test pipes-controller-test |
ef6e2f3
into
aws-controllers-k8s:main
Issue #, if available:
Description of changes:
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.