-
Notifications
You must be signed in to change notification settings - Fork 30
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
feat: reduce meta reconcile time #299
Conversation
@@ -128,6 +129,10 @@ func (p *pvClient) UpdatePersistentVolume(pv *corev1.PersistentVolume) error { | |||
|
|||
return retry.RetryOnConflict(retry.DefaultBackoff, func() error { | |||
if updated, err := p.GetPersistentVolume(pvName); err == nil { | |||
if reflect.DeepEqual(labels, updated.GetLabels()) && reflect.DeepEqual(annotations, updated.GetAnnotations()) { |
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.
Why only compare the lables
and annotations
?
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.
because only update lables and annotations here
) | ||
|
||
const ( | ||
Concurrency = 5 |
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.
It doesn't seem like it needs to be exposed. Also, I feel like there is a lack of modifiers. xxxConcurrency
?
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.
ok
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
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
What type of PR is this?
What problem(s) does this PR solve?
Issue(s) number:
Description:
How do you solve it?
Special notes for your reviewer, ex. impact of this fix, design document, etc: