mirror of https://github.com/k3s-io/k3s
Merge pull request #54531 from MrHohn/fix-lb-tests-nil-panic
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. Fix nil pointer panic in service LB e2e tests **What this PR does / why we need it**: /priority failing-test LB tests on https://k8s-testgrid.appspot.com/sig-network#gci-gce-slow&sort-by-failures= are panicing because of https://github.com/kubernetes/kubernetes/pull/54500. This PR removes the nil pointer passed in by test. I might later send out fix to harden GCE LB codes to check for nil pointer. **Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: ref https://github.com/kubernetes/kubernetes/pull/54500 **Special notes for your reviewer**: Sorry for the noise. /assign @bowei @nicksardo **Release note**: ```release-note NONE ```pull/6/head
commit
c0a519be1f
|
@ -4860,7 +4860,7 @@ func CleanupGCEResources(c clientset.Interface, loadBalancerName, zone string) (
|
|||
if hc != nil {
|
||||
hcNames = append(hcNames, hc.Name)
|
||||
}
|
||||
if err := gceCloud.DeleteExternalTargetPoolAndChecks(nil, loadBalancerName, region, clusterID, hcNames...); err != nil &&
|
||||
if err := gceCloud.DeleteExternalTargetPoolAndChecks(&v1.Service{}, loadBalancerName, region, clusterID, hcNames...); err != nil &&
|
||||
!IsGoogleAPIHTTPErrorCode(err, http.StatusNotFound) {
|
||||
retErr = fmt.Errorf("%v\n%v", retErr, err)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue