tokers commented on a change in pull request #453:
URL: 
https://github.com/apache/apisix-ingress-controller/pull/453#discussion_r638406500



##########
File path: pkg/apisix/cluster.go
##########
@@ -63,6 +77,7 @@ type ClusterOptions struct {
 type cluster struct {
        name         string
        baseURL      string
+       baseURLHost  string

Review comment:
       OK, agree with you :), we can change them in subsequent PRs.

##########
File path: pkg/ingress/controller.go
##########
@@ -317,30 +325,47 @@ election:
 }
 
 func (c *Controller) run(ctx context.Context) {
-       log.Infow("controller now is running as leader",
+       log.Infow("controller tries to leading ...",
                zap.String("namespace", c.namespace),
                zap.String("pod", c.name),
        )
+
+       var cancelFunc context.CancelFunc

Review comment:
       I didn't say we should call `leaderContextCancelFun` in the health 
check. Just call it before the `c.run` return. Or the leader role cannot be 
given up.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to