0
有時在訪問Jedis時,我遇到以下例外情況。在Jedis中獲得例外
異常1:
java.lang.ClassCastException: java.lang.Long cannot be cast to [B
at redis.clients.jedis.Connection.getBinaryBulkReply(Connection.java:204)
at redis.clients.jedis.Connection.getBulkReply(Connection.java:193)
at redis.clients.jedis.Jedis.get(Jedis.java:89)
例外2:
redis.clients.jedis.exceptions.JedisDataException: ERR Protocol error: invalid bulk length
at redis.clients.jedis.Protocol.processError(Protocol.java:113)
at redis.clients.jedis.Protocol.process(Protocol.java:131)
at redis.clients.jedis.Protocol.read(Protocol.java:200)
at redis.clients.jedis.Connection.readProtocolWithCheckingBroken(Connection.java:285)
at redis.clients.jedis.Connection.getBinaryBulkReply(Connection.java:204)
at redis.clients.jedis.Connection.getBulkReply(Connection.java:193)
at redis.clients.jedis.Jedis.get(Jedis.java:89)
誰能幫我解決這個問題?
產生這些錯誤的代碼是什麼? – Turn