debasishg / scala-redis

A scala library for connecting to a redis server, or a cluster of redis nodes using consistent hashing on the client side.
1.02k stars 219 forks source link

Getting values of all the keys #233

Open thedevd opened 5 years ago

thedevd commented 5 years ago

I am not able to find any api, that can allow me to fetch values by passing list of keys. To be more clear I am looking for a method that can accept List of keys as parameter and returns me Map of key value pairs from redis -

 val redis = new RedisClient("localhost", 6379)
 redis.getAll(redis.keys("*").get)) // something like this

Note- I have tried hmgetAll() and hmgetAll1() but that is always returning emptyMap

   val keyValues = redis.hmgetAll1(redis.keys("*"))