// Package define ... // // Description : define ... // // Author : go_developer@163.com<张德满> // // Date : 2021-04-01 5:58 下午 package define // SeverNode 服务器节点的数据结构 // // Author : go_developer@163.com<张德满> // // Date : 2:46 下午 2021/4/1 type SeverNode struct { ID string `json:"id"` // 机器编号 Host string `json:"host"` // ip Port int `json:"port"` // 端口 Weight float64 `json:"weight"` // 权重 Status int `json:"status"` // 状态 Count uint64 `json:"count"` // 节点访问次数, 用于实现最小访问次数的策略 CostTime uint64 `json:"cost_time"` // 节点访问耗时, 用于实现最小访问耗时的策略 FailureCount uint64 `json:"failure_count"` // 节点访问失败次数, 用于实现最小访问失败次数的策略 }