Spring data redis, multi-threading issue with Jedis
问题 I am using redis in a heavily multi-threaded java application and getting intermittent ClassCastException s. Reading through various discussions seemed to point out this might be because the Jedis connection instance getting shared between multiple threads (https://github.com/xetorthio/jedis/issues/359). The solution suggested is to use JedisPool which is thread-safe. I have configured redis through Spring redis support by using RedisTemplate. A thing to note is I am using multiple templates