From e2b6ecd037ed7e07353cc585e38243c525e71696 Mon Sep 17 00:00:00 2001 From: vinllen Date: Mon, 15 Jul 2019 19:17:33 +0800 Subject: [PATCH] support target.db in rump mode --- src/redis-shake/rump.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/redis-shake/rump.go b/src/redis-shake/rump.go index 5ad0624..2a0bb03 100644 --- a/src/redis-shake/rump.go +++ b/src/redis-shake/rump.go @@ -339,6 +339,9 @@ func (dre *dbRumperExecutor) writer() { log.Debugf("dbRumper[%v] executor[%v] skip key %s for expired", dre.rumperId, dre.executorId, ele.key) continue } + if conf.Options.TargetDB != -1 { + ele.db = conf.Options.TargetDB + } log.Debugf("dbRumper[%v] executor[%v] restore[%s], length[%v]", dre.rumperId, dre.executorId, ele.key, len(ele.value))