T Anna wants to draw more attention to this question.
I am using Redis with Spring boot. I am using String as Key and the value against it as a List of complex POJO. Below is my config:
The cahcing is working fine and serialization/deserialization via my app also seems to work. But when i use redis-cli, I see the below when i use the command
Now the value against ABC key should be a list of complex objects. But when I do
I get the value with strange characters as below:
\xac\xed\x00\x05sr\x00\x13java.util.ArrayListx\x81\xd2\x1d\x99\xc7a\x9d\x03\x00\x01I\x00\x04sizexp\x00\x00\x00\x01w\x04\x00\x00\x00\x01sr\x00(com.example. and so on….
Why is it so?
Also, I tried updating GenericJackson2JsonRedisSerializer in the config for valueSerializer to Jackson2JsonRedisSerializer. The result was no different.
Also, I tried to get the TYPE of the key, I get the result as ‘String’, so the list is getting stored as String.
This content was originally published here.