Remove autoweight logic as it's not relevant for local-only setup

parent abcb01ba
......@@ -366,13 +366,6 @@ class ClusterMaster:
'failing': False # Mark as failing after 3 consecutive failures
}
# If this is the first client and weight wasn't explicitly set, change master weight to 0
from .database import get_connected_cluster_clients
connected_clients = get_connected_cluster_clients()
if len(connected_clients) == 1 and self.weight == 100 and not self.weight_explicit:
self.weight = 0
print("First client connected - changing master weight to 0 (automatic)")
backend_type = "GPU" if has_gpu else "CPU-only"
print(f"Client {client_id} authenticated ({backend_type}) with backends: {available_backends}")
return {'type': 'auth_success', 'client_id': client_id}
......@@ -454,10 +447,7 @@ class ClusterMaster:
for proc_type, queue in self.process_queue.items():
self.process_queue[proc_type] = [(k, w) for k, w in queue if k != proc_key]
# If no clients remain and weight wasn't explicitly set, change master weight back to 100
if len(self.clients) == 0 and self.weight == 0 and not self.weight_explicit:
self.weight = 100
print("All clients disconnected - changing master weight back to 100 (automatic)")
# No autoweight logic
print(f"Client {client_id} disconnected")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment