fix healthcheck update problem introduced by #41223

pull/6/head
Minhan Xia 2017-02-13 12:18:42 -08:00
parent 87fe4dca5e
commit 572e3bebcc
1 changed files with 10 additions and 0 deletions

View File

@ -649,7 +649,17 @@ func (proxier *Proxier) OnEndpointsUpdate(allEndpoints []api.Endpoints) {
staleConnections[endpointServicePair{endpoint: ep.ip, servicePortName: svcPort}] = true
}
}
}
// Update service health check
allSvcPorts := make(map[proxy.ServicePortName]bool)
for svcPort := range proxier.endpointsMap {
allSvcPorts[svcPort] = true
}
for svcPort := range newEndpointsMap {
allSvcPorts[svcPort] = true
}
for svcPort := range allSvcPorts {
proxier.updateHealthCheckEntries(svcPort.NamespacedName, svcPortToInfoMap[svcPort])
}