lib/redis_cluster/client.rb in redis_cluster-0.2.6 vs lib/redis_cluster/client.rb in redis_cluster-0.2.7
- old
+ new
@@ -48,9 +48,11 @@
end
private
def reload_pool_nodes(raise_error = false)
+ return @pool.add_node!(@startup_hosts, [(0..Configuration::HASH_SLOTS)]) unless @startup_hosts.is_a? Array
+
@mutex.synchronize do
@startup_hosts.each do |options|
begin
redis = Node.redis(options)
slots_mapping = redis.cluster("slots").group_by{|x| x[2]}