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

Fix GitHub warnings #931

Merged
merged 15 commits into from
Feb 17, 2023
Prev Previous commit
Next Next commit
fix bugs
  • Loading branch information
localvar committed Feb 6, 2023
commit 5b83b5cb7ea9a186c4e3ede47b80808ffaf803b2
3 changes: 2 additions & 1 deletion pkg/filters/proxies/loadbalance.go
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ func (glb *GeneralLoadBalancer) checkServers() {
}
svr.HealthCounter--
if svr.Healthy() && svr.HealthCounter <= -glb.spec.HealthCheck.Fails {
logger.Warnf("server:%v becomes healthy.", svr.ID())
logger.Warnf("server:%v becomes unhealthy.", svr.ID())
svr.Unhealth = true
changed = true
}
Expand Down Expand Up @@ -226,6 +226,7 @@ func (glb *GeneralLoadBalancer) ReturnServer(server *Server, req protocols.Reque
// Close closes the load balancer
func (glb *GeneralLoadBalancer) Close() {
if glb.hc != nil {
close(glb.done)
glb.hc.Close()
}
if glb.ss != nil {
Expand Down