瀏覽代碼

Merge pull request #943 from mavenugo/netdel

getNetworksFromStore should not fail on inconsistent network state
Santhosh Manohar 9 年之前
父節點
當前提交
2bd66ed4d3
共有 1 個文件被更改,包括 2 次插入1 次删除
  1. 2 1
      libnetwork/store.go

+ 2 - 1
libnetwork/store.go

@@ -139,7 +139,8 @@ func (c *controller) getNetworksFromStore() ([]*network, error) {
 			ec := &endpointCnt{n: n}
 			err = store.GetObject(datastore.Key(ec.Key()...), ec)
 			if err != nil {
-				return nil, fmt.Errorf("could not find endpoint count key %s for network %s while listing: %v", datastore.Key(ec.Key()...), n.Name(), err)
+				log.Warnf("could not find endpoint count key %s for network %s while listing: %v", datastore.Key(ec.Key()...), n.Name(), err)
+				continue
 			}
 
 			n.Lock()