Merge pull request #23721 from mrjana/vendor

Vendoring libnetwork @ab62dd6bf06bf0
Upstream-commit: f480bda09fff07bce47c3b037075a76a2226555d
Component: engine
This commit is contained in:
Vincent Demeester
2016-06-19 12:09:19 +02:00
committed by GitHub
3 changed files with 17 additions and 3 deletions

View File

@ -65,7 +65,7 @@ clone git github.com/RackSec/srslog 259aed10dfa74ea2961eddd1d9847619f6e98837
clone git github.com/imdario/mergo 0.2.1
#get libnetwork packages
clone git github.com/docker/libnetwork 13be89d1cf79760acae842a32ad8531567220286
clone git github.com/docker/libnetwork ab62dd6bf06bf0637d66d529931b69a5544468cb
clone git github.com/docker/go-events 39718a26497694185f8fb58a7d6f31947f3dc42d
clone git github.com/armon/go-radix e39d623f12e8e41c7b5529e9a9dd67a1e2261f80
clone git github.com/armon/go-metrics eb0af217e5e9747e41dd5303755356b62d28e3ec

View File

@ -1099,14 +1099,22 @@ func (n *network) getSvcRecords(ep *endpoint) []etchosts.Record {
n.Lock()
defer n.Unlock()
if ep == nil {
return nil
}
var recs []etchosts.Record
sr, _ := n.ctrlr.svcRecords[n.id]
epName := ep.Name()
for h, ip := range sr.svcMap {
if ep != nil && strings.Split(h, ".")[0] == ep.Name() {
if strings.Split(h, ".")[0] == epName {
continue
}
if len(ip) == 0 {
log.Warnf("Found empty list of IP addresses for service %s on network %s (%s)", h, n.Name(), n.ID())
continue
}
recs = append(recs, etchosts.Record{
Hosts: h,
IP: ip[0].String(),

View File

@ -397,6 +397,12 @@ func (nDB *NetworkDB) bulkSyncNode(networks []string, node string, unsolicited b
return false
}
// Do not bulk sync state which is in the
// process of getting deleted.
if entry.deleting {
return false
}
params := strings.Split(path[1:], "/")
tEvent := TableEvent{
Type: TableEventTypeCreate,