Recently encountered a problem, using the incr count, stored in a number (int type), but because it is serialized after the memory, call the INCR method when the error:
caused By:redis.clients.jedis.exceptions.JedisDataException:ERR value is not a integer or out of range
At Redis.clients.jedis.Protocol.processError (protocol.java:115)
At Redis.clients.jedis.Protocol.process (protocol.java:133)
At Redis.clients.jedis.Protocol.read (protocol.java:202)
At Redis.clients.jedis.Connection.readProtocolWithCheckingBroken (connection.java:285)
At Redis.clients.jedis.Connection.getIntegerReply (connection.java:210)
At Redis.clients.jedis.Jedis.incrBy (jedis.java:556)
At Com.dangdang.framework.redis.jedis.cluster.core.SingleJedisClientImpl.incrBy (singlejedisclientimpl.java:119)
... Bayi Common frames omitted
WORKAROUND: Use Set (String key,string value) directly when it is stored and do not serialize value.
ERR value is not a integer or out of range