node.go 410 B

1234567891011121314151617181920212223
  1. package model
  2. // NodeStatus Status of instance
  3. type NodeStatus int
  4. const (
  5. // AppID is discvoery id
  6. AppID = "infra.discovery"
  7. )
  8. const (
  9. // NodeStatusUP Ready to receive register
  10. NodeStatusUP NodeStatus = iota
  11. // NodeStatusLost lost with each other
  12. NodeStatusLost
  13. )
  14. // Node node
  15. type Node struct {
  16. Addr string `json:"addr"`
  17. Status NodeStatus `json:"status"`
  18. Zone string `json:"zone"`
  19. }