mirror of
https://github.com/redis/redis.git
synced 2026-04-21 03:01:35 -04:00
redis-trib: when loading node info also fetch the output of CLUSTER INFO.
This commit is contained in:
@@ -96,6 +96,15 @@ class ClusterNode
|
||||
end
|
||||
}
|
||||
@dirty = false
|
||||
@r.cluster("info").split("\n").each{|e|
|
||||
k,v=e.split(":")
|
||||
k = k.to_sym
|
||||
if k != :cluster_state
|
||||
@info[k] = v.to_i
|
||||
else
|
||||
@info[k] = v
|
||||
end
|
||||
}
|
||||
elsif o[:getfriends]
|
||||
@friends << info
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user