polish log print2

v4
vinllen 5 years ago
parent 082a080faa
commit ee4453fb50
  1. 4
      src/redis-shake/dump.go
  2. 4
      src/redis-shake/sync.go

@ -141,10 +141,10 @@ func (dd *dbDumper) sendCmd(master, auth_type, passwd string, tlsEnable bool) (n
select { select {
case nsize = <-wait: case nsize = <-wait:
if nsize == 0 { if nsize == 0 {
log.Infof("routine[%v] + waiting rdb done", dd.id) log.Infof("routine[%v] + waiting source rdb", dd.id)
} }
case <-time.After(time.Second): case <-time.After(time.Second):
log.Infof("routine[%v] - waiting rdb done", dd.id) log.Infof("routine[%v] - waiting source rdb", dd.id)
} }
} }
return c, nsize return c, nsize

@ -264,12 +264,12 @@ func (ds *dbSyncer) sendSyncCmd(master, auth_type, passwd string, tlsEnable bool
select { select {
case nsize := <-wait: case nsize := <-wait:
if nsize == 0 { if nsize == 0 {
log.Infof("dbSyncer[%v] + waiting rdb done", ds.id) log.Infof("dbSyncer[%v] + waiting source rdb", ds.id)
} else { } else {
return c, nsize return c, nsize
} }
case <-time.After(time.Second): case <-time.After(time.Second):
log.Infof("dbSyncer[%v] - waiting rdb done", ds.id) log.Infof("dbSyncer[%v] - waiting source rdb", ds.id)
} }
} }
} }

Loading…
Cancel
Save