Skip to content

Commit 7ce6fcb

Browse files
authored
Merge pull request #232 from chengxiangdong/feat
Ignore services with empty loadbalancerClass if enabling loadbalancerClass
2 parents 4fa5870 + 50488e7 commit 7ce6fcb

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

pkg/cloudprovider/huaweicloud/huaweicloud.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -571,6 +571,11 @@ func (h *CloudProvider) Initialize(clientBuilder cloudprovider.ControllerClientB
571571

572572
// TCPLoadBalancer returns an implementation of TCPLoadBalancer for Huawei Web Services.
573573
func (h *CloudProvider) LoadBalancer() (cloudprovider.LoadBalancer, bool) {
574+
// Only services with LoadBalancerClass=huaweicloud.com/elb are processed.
575+
if h.loadbalancerOpts.LoadBalancerClass != "" {
576+
return nil, false
577+
}
578+
574579
return h, true
575580
}
576581

0 commit comments

Comments
 (0)