send initial list of volume location

This commit is contained in:
Chris Lu
2018-07-28 01:17:35 -07:00
parent a12c7b86b0
commit e8d4be579d
2 changed files with 29 additions and 0 deletions

View File

@@ -143,6 +143,12 @@ func (ms *MasterServer) KeepConnected(stream master_pb.Seaweed_KeepConnectedServ
ms.clientChansLock.Unlock()
}()
for _, message := range ms.Topo.ToVolumeLocations() {
if err := stream.Send(message); err != nil {
return err
}
}
go func() {
for {
_, err := stream.Recv()