Merge pull request #129298 from omerap12/fix-discovery-controller-panic

apiextensions: replace panic with error handling in DiscoveryController
This commit is contained in:
Kubernetes Prow Robot 2025-01-09 09:04:31 -08:00 committed by GitHub
commit e319c541f1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -320,7 +320,8 @@ func (c *DiscoveryController) Run(stopCh <-chan struct{}, synchedCh chan<- struc
utilruntime.HandleError(fmt.Errorf("timed out waiting for initial discovery sync"))
return
}
panic(fmt.Errorf("unexpected error: %v", err))
utilruntime.HandleError(fmt.Errorf("unexpected error: %w", err))
return
}
close(synchedCh)