This commit is contained in:
刘河
2019-02-16 23:18:58 +08:00
parent 3b18d66835
commit 7a8cb3d5b6
14 changed files with 243 additions and 217 deletions

View File

@@ -123,6 +123,7 @@ func (s *TRPClient) linkProcess(link *conn.Link, c *conn.Conn) {
c.Close()
break
}
lg.Println("send ok", link.Id)
}
}
pool.PutBufPoolCopy(buf)

View File

@@ -7,6 +7,7 @@ import (
"log"
"os"
"path/filepath"
"strconv"
"strings"
)
@@ -41,10 +42,19 @@ func GetTaskStatus(path string) {
}
}
for _, v := range cnf.Tasks {
if common.InArr(arr, v.Remark) {
log.Println(v.Remark, "ok")
} else {
log.Println(v.Remark, "not running")
ports := common.GetPorts(v.Ports)
for _, vv := range ports {
var remark string
if len(ports) > 1 {
remark = v.Remark + "_" + strconv.Itoa(vv)
} else {
remark = v.Remark
}
if common.InArr(arr, remark) {
log.Println(remark, "ok")
} else {
log.Println(remark, "not running")
}
}
}
}