Documentation ¶
Index ¶
- Constants
- type CNInstance
- type CNStatus
- type DeletedSession
- type HAKeeperStatus
- type LockItem
- type LockStatus
- type LogtailServerStatus
- type NodeStatus
- type Server
- func (s *Server) Dump() ([]byte, error)
- func (s *Server) ServeHTTP(w http.ResponseWriter, _ *http.Request)
- func (s *Server) SetHAKeeperClient(c logservice.ClusterHAKeeperClient)
- func (s *Server) SetLockService(uuid string, l lockservice.LockService)
- func (s *Server) SetLogtailServer(logtailServer *service.LogtailServer)
- func (s *Server) SetTxnClient(uuid string, c client.TxnClient)
- type SessionStatus
- type Status
- type TxnClientStatus
Constants ¶
View Source
const JsonIdent = " "
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CNInstance ¶
type CNInstance struct { TxnClient client.TxnClient LockService lockservice.LockService }
type CNStatus ¶
type CNStatus struct { TxnClientStatus TxnClientStatus `json:"txn_client_status"` LockStatus LockStatus `json:"lock_status"` }
type DeletedSession ¶
type HAKeeperStatus ¶
type HAKeeperStatus struct { Nodes []NodeStatus `json:"nodes"` DeletedNodes []NodeStatus `json:"deleted_nodes"` ErrMsg string `json:"err_msg"` }
HAKeeperStatus contains the status of HAKeeper. Currently, we focus on the uptime/downtime of nodes in HAKeeper.
type LockStatus ¶
type LockStatus struct {
Locks []LockItem `json:"locks"`
}
type LogtailServerStatus ¶
type LogtailServerStatus struct { Sessions []SessionStatus `json:"session_status"` DeletedSessions []DeletedSession `json:"deleted_sessions"` }
type NodeStatus ¶
type NodeStatus struct { NodeID string `json:"node_id"` NodeType string `json:"node_type"` Address string `json:"address"` Labels map[string]metadata.LabelList `json:"Labels"` WorkState metadata.WorkState `json:"WorkState"` Resource pb.Resource `json:"Resource"` UpTime time.Time `json:"up_time"` DownTime time.Time `json:"down_time"` }
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
func (*Server) SetHAKeeperClient ¶
func (s *Server) SetHAKeeperClient(c logservice.ClusterHAKeeperClient)
func (*Server) SetLockService ¶
func (s *Server) SetLockService(uuid string, l lockservice.LockService)
func (*Server) SetLogtailServer ¶
func (s *Server) SetLogtailServer(logtailServer *service.LogtailServer)
type SessionStatus ¶
type Status ¶
type Status struct { LogtailServerStatus LogtailServerStatus `json:"logtail_server_status"` HAKeeperStatus HAKeeperStatus `json:"hakeeper_status"` CNUUIDStatus map[string]*CNStatus `json:"cn_uuid_status"` }
type TxnClientStatus ¶
type TxnClientStatus struct { // indicate whether the CN can provide service normally. // 0 means paused, 1 means normal. State int `json:"state"` // number of user active transactions. UserTxnNum int `json:"user_txn_num"` // all active txns ActiveTxns []string `json:"active_txns"` ActiveTxnCount int `json:"active_txn_count"` // FIFO queue for ready to active txn WaitActiveTxns []string `json:"wait_active_txns"` WaitActiveTxnCount int `json:"wait_active_txn_count"` // LatestTS is the latest TS for the txn client. LatestTS timestamp.Timestamp `json:"latest_ts"` }
Click to show internal directories.
Click to hide internal directories.