Println 打印普通信息
(tag string, description string)
| 48 | |
| 49 | // Println 打印普通信息 |
| 50 | func Println(tag string, description string) { |
| 51 | logs.Println("[" + tag + "]" + description) |
| 52 | |
| 53 | select { |
| 54 | case logChan <- &pb.NodeLog{ |
| 55 | Role: teaconst.Role, |
| 56 | Tag: tag, |
| 57 | Description: description, |
| 58 | Level: "info", |
| 59 | NodeId: teaconst.NodeId, |
| 60 | CreatedAt: time.Now().Unix(), |
| 61 | }: |
| 62 | default: |
| 63 | } |
| 64 | } |
| 65 | |
| 66 | // Warn 打印警告信息 |
| 67 | func Warn(tag string, description string) { |