Merge pull request #84 from zjhgoodrain/3.6-dev

This commit is contained in:
zjhgoodrain 2018-06-14 19:01:48 +08:00 committed by GitHub
commit 8dba832495
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -14,6 +14,7 @@ import (
"os"
"strings"
"github.com/docker/engine-api/client"
"fmt"
)
//Resource should be clean resource
@ -210,7 +211,9 @@ func QueryK8sServiceResource(m *Manager) []Resource {
if err != nil {
logrus.Error(err)
}
fmt.Println("ServivesMap",ServivesMap)
for _, v := range ServicesList.Items {
fmt.Println("service",v.Namespace,v.Name)
val, ok := ServivesMap[v.Namespace]
if ok {
if !InSlice(v.Name, val) {
@ -388,7 +391,7 @@ logrus.Info("StatefulSetList",StatefulSetList)
func (n *nameSpacesResource) IsTimeout() bool {
now := time.Now()
if now.After(n.createTime.Add(time.Second * 10)) {
if now.After(n.createTime.Add(time.Minute * 5)) {
return true
}
return false