github.com/GeniusesGroup/libgo@v0.0.0-20220929090155-5ff932cb408e/achaemenid/node.go (about) 1 /* For license and copyright information please see LEGAL file in repository */ 2 3 package achaemenid 4 5 // Node store details about a node that part of the platfrom. 6 type Node struct { 7 InstanceID [32]byte 8 ID uint64 9 dataCenterID [32]byte 10 storageCapacity uint64 // In bytes, Max 16EB(Exabyte) that more enough for one node capacity. 0 means service only node. 11 Conn *Connection 12 State nodeState 13 } 14 15 type nodeState uint8 16 17 // Node State 18 const ( 19 NodeStateLocalNode nodeState = iota 20 NodeStateStable 21 NodeStateStop 22 NodeStateStoping 23 NodeStateStart 24 NodeStateStarting 25 NodeStateNotResponse 26 ) 27 28 // NodeDetails ... 29 type NodeDetails struct { 30 ID uint64 31 // GPAddr gp.Addr 32 // IPAddr ip.Addr 33 }