mirror of
https://gitcode.com/JianFeeeee/webui4frpc.git
synced 2026-09-21 09:27:57 +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:
@ -173,3 +173,48 @@ export interface CacheResp {
|
||||
cache: CacheEntry[];
|
||||
removed?: string[];
|
||||
}
|
||||
|
||||
// M6 token-ring snapshot (GET /cluster/ring).
|
||||
export interface RingNode {
|
||||
id: string;
|
||||
addr: string;
|
||||
isLeader?: boolean;
|
||||
alive: boolean;
|
||||
load: { memPct: number; netPct: number };
|
||||
version?: string;
|
||||
cache?: string[];
|
||||
lastSeen?: number;
|
||||
}
|
||||
|
||||
export interface RingTaskInfo {
|
||||
id: string;
|
||||
local: { name: string };
|
||||
remote: { name: string };
|
||||
link: { remotePort?: number };
|
||||
}
|
||||
|
||||
export interface RingTopoEntry {
|
||||
taskId: string;
|
||||
ownerId: string;
|
||||
active: boolean;
|
||||
local: { name: string };
|
||||
remote: { name: string };
|
||||
link: { remotePort?: number };
|
||||
}
|
||||
|
||||
export interface RingLogEntry {
|
||||
seq: number;
|
||||
node: string;
|
||||
kind: string;
|
||||
at?: number;
|
||||
}
|
||||
|
||||
export interface RingSnapshot {
|
||||
leaderId: string;
|
||||
cycle: number;
|
||||
roundDelayMs?: number;
|
||||
nodes: RingNode[];
|
||||
pending: RingTaskInfo[];
|
||||
topology: RingTopoEntry[];
|
||||
log: RingLogEntry[];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user