-
Notifications
You must be signed in to change notification settings - Fork 16
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
chore: use ack provider to resolve the cluster cni #95
Conversation
Thanks to your contribution, the maintainers will review it as soon as they can! |
cc @helen-frank for checking |
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.
resolve pre-submit check
/lgtm
pkg/providers/ack/ack.go
Outdated
ackClient: ackClient, | ||
clusterID: clusterID, | ||
ackClient: ackClient, | ||
clusterCNI: "", |
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 an empty string necessary here?
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.
Not necessary, thanks for suggestion
func (p *DefaultProvider) LivenessProbe(_ *http.Request) error { | ||
p.muClusterCNI.Lock() | ||
//nolint: staticcheck | ||
p.muClusterCNI.Unlock() |
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 there any write operation here? Maybe it doesn't need the lock and unlock operation if just a read operation.
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's used to check whether it is in dead-lock state. aws provider does this.
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.
Gotcha.
Signed-off-by: jwcesign <jwcesign@cloudpilot.ai>
What type of PR is this?
/kind feature
What this PR does / why we need it:
chore: use ack provider to resolve the cluster cni
Which issue(s) this PR fixes:
Fixes #91
Special notes for your reviewer:
Does this PR introduce a user-facing change?