From 939c586ef74bbfbaa5fa88b270734a9332d7ca63 Mon Sep 17 00:00:00 2001 From: antirez Date: Mon, 12 May 2014 10:22:04 +0200 Subject: [PATCH] redis-trib.rb: MIGRATE hardcoded timeout set to 15 sec. Will be configurable / adaptive at some point but let's start with a saner value compared to 1 sec which is not a good idea for big data structures stored into a single key. --- src/redis-trib.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/redis-trib.rb b/src/redis-trib.rb index 81e0d8f55a1..b6f6aba39f8 100755 --- a/src/redis-trib.rb +++ b/src/redis-trib.rb @@ -724,7 +724,7 @@ def move_slot(source,target,slot,o={}) keys = source.r.cluster("getkeysinslot",slot,10) break if keys.length == 0 keys.each{|key| - source.r.client.call(["migrate",target.info[:host],target.info[:port],key,0,1000]) + source.r.client.call(["migrate",target.info[:host],target.info[:port],key,0,15000]) print "." if o[:verbose] STDOUT.flush } @@ -1024,7 +1024,7 @@ def import_cluster_cmd(argv,opt) slot = key_to_slot(k) target = slots[slot] puts "Migrating #{k} to #{target}" - source.client.call(["migrate",target.info[:host],target.info[:port],k,0,1000]) + source.client.call(["migrate",target.info[:host],target.info[:port],k,0,15000]) } end end