Skip to content

Commit

Permalink
Merge pull request kubernetes-sigs#4442 from lzhecheng/cp-4439-1.26
Browse files Browse the repository at this point in the history
[release-1.26] Improve e2e and ensureBackendPoolDeletedFromVmssUniform log
  • Loading branch information
k8s-ci-robot authored Aug 11, 2023
2 parents 73b3275 + 797874d commit 8a645ee
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
7 changes: 3 additions & 4 deletions pkg/provider/azure_vmss.go
Original file line number Diff line number Diff line change
Expand Up @@ -1699,8 +1699,6 @@ func (ss *ScaleSet) ensureBackendPoolDeletedFromVMSS(backendPoolID, vmSetName st
}

func (ss *ScaleSet) ensureBackendPoolDeletedFromVmssUniform(backendPoolID, vmSetName string) error {
klog.V(2).Infof("ensureBackendPoolDeletedFromVmssUniform: vmSetName (%s), backendPoolID (%s)", vmSetName, backendPoolID)

vmssNamesMap := make(map[string]bool)
// the standard load balancer supports multiple vmss in its backend while the basic sku doesn't
if ss.useStandardLoadBalancer() && !ss.EnableMultipleStandardLoadBalancers {
Expand All @@ -1719,7 +1717,7 @@ func (ss *ScaleSet) ensureBackendPoolDeletedFromVmssUniform(backendPoolID, vmSet
} else if v, ok := value.(*compute.VirtualMachineScaleSet); ok {
vmss = v
}
klog.V(2).Infof("ensureBackendPoolDeletedFromVmssUniform: vmss (%s)", pointer.StringDeref(vmss.Name, ""))
klog.V(2).Infof("ensureBackendPoolDeletedFromVmssUniform: vmss %q, backendPoolID %q", pointer.StringDeref(vmss.Name, ""), backendPoolID)

// When vmss is being deleted, CreateOrUpdate API would report "the vmss is being deleted" error.
// Since it is being deleted, we shouldn't send more CreateOrUpdate requests for it.
Expand Down Expand Up @@ -1769,6 +1767,7 @@ func (ss *ScaleSet) ensureBackendPoolDeletedFromVmssUniform(backendPoolID, vmSet
return utilerrors.Flatten(utilerrors.NewAggregate(errorList))
}
} else {
klog.V(2).Infof("ensureBackendPoolDeletedFromVmssUniform: vmss %q, backendPoolID %q", vmSetName, backendPoolID)
vmssNamesMap[vmSetName] = true
}

Expand Down Expand Up @@ -1941,7 +1940,7 @@ func (ss *ScaleSet) EnsureBackendPoolDeleted(service *v1.Service, backendPoolID,
vmssFlexBackendIPConfigurations = append(vmssFlexBackendIPConfigurations, ipConf)
}
if vmManagementType == ManagedByVmssUniform {
// vm is managed by vmss flex.
// vm is managed by vmss uniform.
vmssUniformBackendIPConfigurations = append(vmssUniformBackendIPConfigurations, ipConf)
}
}
Expand Down
2 changes: 2 additions & 0 deletions tests/e2e/utils/service_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,8 @@ func WaitServiceExposure(cs clientset.Interface, namespace string, name string,

return true, nil
}); err != nil {
output, _ := RunKubectl(namespace, "describe", "service", name)
Logf("Service describe info: %s", output)
return nil, err
}

Expand Down

0 comments on commit 8a645ee

Please sign in to comment.