|
@ -43,7 +43,10 @@ func (ms *MasterServer) SendHeartbeat(stream master_pb.Seaweed_SendHeartbeatServ |
|
|
|
|
|
|
|
|
for { |
|
|
for { |
|
|
heartbeat, err := stream.Recv() |
|
|
heartbeat, err := stream.Recv() |
|
|
if err == nil { |
|
|
|
|
|
|
|
|
if err != nil { |
|
|
|
|
|
return err |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
if dn == nil { |
|
|
if dn == nil { |
|
|
t.Sequence.SetMax(heartbeat.MaxFileKey) |
|
|
t.Sequence.SetMax(heartbeat.MaxFileKey) |
|
|
if heartbeat.Ip == "" { |
|
|
if heartbeat.Ip == "" { |
|
@ -90,10 +93,6 @@ func (ms *MasterServer) SendHeartbeat(stream master_pb.Seaweed_SendHeartbeatServ |
|
|
ms.clientChansLock.RUnlock() |
|
|
ms.clientChansLock.RUnlock() |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
return err |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// tell the volume servers about the leader
|
|
|
// tell the volume servers about the leader
|
|
|
newLeader, err := t.Leader() |
|
|
newLeader, err := t.Leader() |
|
|
if err == nil { |
|
|
if err == nil { |
|
|