panlei
2019-11-01 e6982607fbbeaa96d3d14409df780266646b793d
main.go
@@ -7,16 +7,18 @@
   "net/http"
   _ "net/http/pprof"
   "ruleprocess/insertdata"
   "ruleprocess/labelFilter"
   "ruleprocess/structure"
   "ruleprocess/util"
   "time"
   "basic.com/valib/logger.git"
   //"bufio"
   //"bytes"
   "flag"
   "fmt"
   "github.com/golang/protobuf/proto"
   "basic.com/valib/logger.git"
   "github.com/spf13/viper"
   //"gocv.io/x/gocv"
   //"image"
   //"image/color"
@@ -24,7 +26,6 @@
   "ruleprocess/cache"
   "ruleprocess/ruleserver"
   "sync"
   "github.com/spf13/viper"
)
var dbIp = flag.String("dbIp", "127.0.0.1", "dbserver ip")
@@ -62,6 +63,7 @@
   go cache.Init(initchan, *dbIp, *surveyPort, *pubPort)
   logger.Info("cache init completed!!!", <-initchan) //dbserver初始化完毕
   ruleserver.Init()
   labelFilter.Init()
   go ruleserver.TimeTicker()
   go ruleserver.StartServer()
   nReciever("ipc:///tmp/sdk-2-rules-process.ipc", deliver.PushPull, 1)
@@ -106,7 +108,7 @@
               insertdata.InsertToEs(resultMsg)
               logger.Debug("插入完Es所用时间:", time.Since(start))
               //事件推送
               //go labelFilter.Judge(resultMsg)
               labelFilter.PushSomthing(resultMsg)
            //}(msg)
         }
      }