conductor(checkpoint): Checkpoint end of Phase 1

This commit is contained in:
2026-02-08 11:15:55 -08:00
parent 22ec8a5cc0
commit 860000bd04
8 changed files with 204 additions and 50 deletions

View File

@@ -26,15 +26,19 @@ def format_summary(cluster_data, use_color=True):
f"{BOLD}Cluster Health:{RESET} {colorize(health, color, use_color)}",
f"{BOLD}Total Nodes:{RESET} {len(cluster_data['nodes'])}",
f"{BOLD}Primaries:{RESET} {cluster_data['primary_count']}",
"-" * 30
]
if not cluster_data.get("nomad_available", True):
summary.append(colorize("WARNING: Nomad CLI unavailable or connectivity failed. Logs and uptime may be missing.", RED, use_color))
summary.append("-" * 30)
return "\n".join(summary)
def format_node_table(nodes, use_color=True):
"""
Formats the node list as a table.
"""
headers = ["Node", "Role", "Consul Status", "LiteFS Role", "Uptime", "Replication Lag", "LiteFS Info"]
headers = ["Node", "Role", "Consul Status", "LiteFS Role", "Uptime", "Lag", "DBs", "LiteFS Info"]
table_data = []
for node in nodes:
@@ -74,8 +78,9 @@ def format_node_table(nodes, use_color=True):
colored_role,
colored_status,
colored_litefs_role,
node["uptime"],
node["replication_lag"],
node.get("uptime", "N/A"),
node.get("replication_lag", "N/A"),
", ".join(node.get("active_dbs", [])),
info
])