func doGet(id string, signal chan int, client redis.Client, cnt int) { key := "set-" + id for i := 0; i < cnt; i++ { client.Get(key) } signal <- 1 }
func doGet(client redis.Client, cnt int) (delta time.Duration) { key := "ctr" t0 := time.Now() for i := 0; i < cnt; i++ { client.Get(key) } delta = time.Now().Sub(t0) client.Flushdb() return }