replace https://github.com/seaweedfs/seaweedfs/pull/3621
This commit is contained in:
@@ -32,7 +32,9 @@ func (r *Rack) FindDataNode(ip string, port int) *DataNode {
|
||||
return nil
|
||||
}
|
||||
func (r *Rack) GetOrCreateDataNode(ip string, port int, grpcPort int, publicUrl string, maxVolumeCounts map[string]uint32) *DataNode {
|
||||
for _, c := range r.Children() {
|
||||
r.Lock()
|
||||
defer r.Unlock()
|
||||
for _, c := range r.children {
|
||||
dn := c.(*DataNode)
|
||||
if dn.MatchLocation(ip, port) {
|
||||
dn.LastSeen = time.Now().Unix()
|
||||
|
||||
Reference in New Issue
Block a user