aboutsummaryrefslogtreecommitdiff
path: root/weed/server/master_grpc_server.go
diff options
context:
space:
mode:
authorChris Lu <chris.lu@gmail.com>2021-11-05 17:52:15 -0700
committerChris Lu <chris.lu@gmail.com>2021-11-05 17:52:15 -0700
commit5ea86ef1dabfa6267eb68c1ef82939910f2d3505 (patch)
tree2957313fd024567eb8bb410468f1355c6706ae7a /weed/server/master_grpc_server.go
parent314c32514b1134f5605ca8bc3e1cdf785943b53b (diff)
downloadseaweedfs-5ea86ef1dabfa6267eb68c1ef82939910f2d3505.tar.xz
seaweedfs-5ea86ef1dabfa6267eb68c1ef82939910f2d3505.zip
Revert "master: rename grpc function KeepConnected() to SubscribeVolumeLocationUpdates()"
This reverts commit af71ae11aa29350a60ed7d3b9a16276a06ba9dcc.
Diffstat (limited to 'weed/server/master_grpc_server.go')
-rw-r--r--weed/server/master_grpc_server.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/weed/server/master_grpc_server.go b/weed/server/master_grpc_server.go
index 756e80d57..53e28c5bf 100644
--- a/weed/server/master_grpc_server.go
+++ b/weed/server/master_grpc_server.go
@@ -176,9 +176,9 @@ func (ms *MasterServer) SendHeartbeat(stream master_pb.Seaweed_SendHeartbeatServ
}
}
-// SubscribeVolumeLocationUpdates keep a stream gRPC call to the master. Used by clients to know the master is up.
+// KeepConnected keep a stream gRPC call to the master. Used by clients to know the master is up.
// And clients gets the up-to-date list of volume locations
-func (ms *MasterServer) SubscribeVolumeLocationUpdates(stream master_pb.Seaweed_SubscribeVolumeLocationUpdatesServer) error {
+func (ms *MasterServer) KeepConnected(stream master_pb.Seaweed_KeepConnectedServer) error {
req, recvErr := stream.Recv()
if recvErr != nil {
@@ -238,7 +238,7 @@ func (ms *MasterServer) SubscribeVolumeLocationUpdates(stream master_pb.Seaweed_
}
-func (ms *MasterServer) informNewLeader(stream master_pb.Seaweed_SubscribeVolumeLocationUpdatesServer) error {
+func (ms *MasterServer) informNewLeader(stream master_pb.Seaweed_KeepConnectedServer) error {
leader, err := ms.Topo.Leader()
if err != nil {
glog.Errorf("topo leader: %v", err)
@@ -257,7 +257,7 @@ func (ms *MasterServer) addClient(clientType string, clientAddress pb.ServerAddr
glog.V(0).Infof("+ client %v", clientName)
// we buffer this because otherwise we end up in a potential deadlock where
- // the SubscribeVolumeLocationUpdates loop is no longer listening on this channel but we're
+ // the KeepConnected loop is no longer listening on this channel but we're
// trying to send to it in SendHeartbeat and so we can't lock the
// clientChansLock to remove the channel and we're stuck writing to it
// 100 is probably overkill