mirror of
https://gitcode.com/JianFeeeee/webui4frpc.git
synced 2026-10-15 03:42:30 +00:00
feat(web): cluster page shows token ring — ring topology/leader/load, pending tasks, active forward topology with owner, incremental log sync view (e2e verified)
This commit is contained in:
@ -29,19 +29,19 @@ const (
|
||||
|
||||
// LogEntry is one immutable, append-only cluster operation.
|
||||
type LogEntry struct {
|
||||
Seq int64 `json:"seq"`
|
||||
Node string `json:"node"`
|
||||
Kind string `json:"kind"`
|
||||
Data json.RawMessage `json:"data,omitempty"`
|
||||
At int64 `json:"at"`
|
||||
Seq int64 `json:"seq"`
|
||||
Node string `json:"node"`
|
||||
Kind string `json:"kind"`
|
||||
Data json.RawMessage `json:"data,omitempty"`
|
||||
At int64 `json:"at"`
|
||||
}
|
||||
|
||||
// ClusterLog is a node's local operation log with a sync watermark.
|
||||
type ClusterLog struct {
|
||||
mu sync.Mutex
|
||||
Seq int64 // highest local seq issued
|
||||
Log []LogEntry // append-only
|
||||
Synced int64 // watermark: entries <= this are known to remote nodes
|
||||
mu sync.Mutex
|
||||
Seq int64 // highest local seq issued
|
||||
Log []LogEntry // append-only
|
||||
Synced int64 // watermark: entries <= this are known to remote nodes
|
||||
}
|
||||
|
||||
// NewClusterLog creates an empty log with initial sequence.
|
||||
|
||||
Reference in New Issue
Block a user