mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-10 04:27:54 +00:00
fix openapi/v3 non local apiservices aggregation
When resyncing APIServices (every minute), the AggregationController calls AddUpdateAPIService immediately, but it may take some time before the reconciliation of the controller calls UpdateAPIServiceSpec. This results in a temporary downtime of discovery of these APIServices, which will stop reporting of these in the aggregated openapi/v3 by specProxier. This fix ensures that old discovery is kept during a time, when the AggregationController is reconciling.
This commit is contained in:
parent
ba6d2674ca
commit
3df92362ab
@ -114,6 +114,7 @@ func (s *specProxier) AddUpdateAPIService(handler http.Handler, apiservice *v1.A
|
||||
if apiServiceInfo, ok := s.apiServiceInfo[apiservice.Name]; ok {
|
||||
apiServiceInfo.apiService = *apiservice
|
||||
apiServiceInfo.handler = handler
|
||||
return
|
||||
}
|
||||
s.apiServiceInfo[apiservice.Name] = &openAPIV3APIServiceInfo{
|
||||
apiService: *apiservice,
|
||||
|
Loading…
Reference in New Issue
Block a user