systemMonitor.go 619 B

12345678910111213141516171819202122232425262728
  1. package monitor
  2. func StartSystem() {
  3. s1 := new(systemMonitor)
  4. go s1.initCache()
  5. }
  6. //系统级行为监控
  7. type systemMonitor struct {
  8. }
  9. //初始化缓存业务数据
  10. func (t *systemMonitor) initCache() {
  11. /*
  12. scdmgr := new(bo.ScdMgr)
  13. node := new(bo.ScdNode)
  14. scdall, _ := scdmgr.List(map[string]interface{}{})
  15. if len(scdall) == 0 {
  16. return
  17. }
  18. for _, row := range scdall {
  19. //缓存每个scd的设备网络IP及mac信息
  20. //scdmgr.GetIedNetAddr(tools.IsEmpty(row["id"]))
  21. //缓存每个scd的IED关系
  22. //node.GetIedRelations(map[string]interface{}{"scd_id": tools.IsEmpty(row["id"])})
  23. }
  24. */
  25. }