You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I set the value like this:
jredis.set(key,value);
jredis.expire(key, expiretime_seconds);
and when I try to get the value like this:
String value = DefaultCodec.decode(jredis.get(key));
it said :
java.lang.RuntimeException: Error decoding byte[] data to instantiate java object - data at key may not have been of this type or even an object
org.jredis.ri.alphazero.support.DefaultCodec.decode(DefaultCodec.java:218)
so is it a bug or I made someting wrong when I set or get the volatile value? thank you very much~
by the way,I use the lastest jredis source(compile it in eclipse myself) and redis 1.2.6
The text was updated successfully, but these errors were encountered:
Its not a bug. You should use the toStr(...) methods to get String and String[]. decode(..) is strictly for serialized java objects that are not either byte[], String, or Number.
I set the value like this:
jredis.set(key,value);
jredis.expire(key, expiretime_seconds);
and when I try to get the value like this:
String value = DefaultCodec.decode(jredis.get(key));
it said :
java.lang.RuntimeException: Error decoding byte[] data to instantiate java object - data at key may not have been of this type or even an object
org.jredis.ri.alphazero.support.DefaultCodec.decode(DefaultCodec.java:218)
so is it a bug or I made someting wrong when I set or get the volatile value? thank you very much~
by the way,I use the lastest jredis source(compile it in eclipse myself) and redis 1.2.6
The text was updated successfully, but these errors were encountered: