JsonParseException: Unrecognized token '': was expecting ('true', 'false' or 'null')
See original GitHub issueOn the redis-cli
, when I run:
hgetall id:3bb536598d71
I see
1) "id"
2) "\"811\""
3) "item"
4) "[{\"id\": \"4429\", \"validity\": {\"startDate\": \"2018-12-06T00:00:00\", \"endDate\": \"2018-12-08T23:00:00\"}]"
5) "show"
6) "true"
But when I run:
Config config = new Config();
config.useSingleServer().setAddress("redis://127.0.0.1:6379");
RedissonClient client = Redisson.create(config);
RMap<String, Object> map = client.getMap("id:3bb536598d71");
map.readAllEntrySet().forEach(System.out::println);
It is throwing an exception.
Caused by: com.fasterxml.jackson.core.JsonParseException: Unrecognized token 'show': was expecting ('true', 'false' or 'null')
at [Source: (io.netty.buffer.ByteBufInputStream); line: 1, column: 15]
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Unrecognized token 'http': was expecting ('true', 'false' or 'null ...
So I suspect that the parser is trying to parse something different than this string when the error occurs. You need to find...
Read more >Unrecognized token 'Request': was expecting ('true', 'false' or ...
nested exception is com.fasterxml.jackson.core.JsonParseException: I validated that My JSON value is correct using http://json.parser.online.fr/ and ...
Read more >How to solve JSON parse error: Unrecognized token issue in ...
JsonParseException : Unrecognized token 'uid': was expecting (JSON String, Number, Array, Object or token 'null', 'true' or 'false')\n at ...
Read more >Java – Error Caused by: com.fasterxml.jackson.core ...
Java – JsonParseException: Unrecognized token 'http': was expecting ('true', 'false' or 'null'). We have the following string which is a valid JSON ...
Read more >Attributes argument is not working, I have tried to filter by ...
JsonParseException : Unrecognized token 'attributes': was expecting ('true', 'false' or 'null')\n at [Source: (PushbackInputStream); line: 1, ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
It appears the field and value of the hash do not have the same encoding scheme. The field seemed to be plain string whereas value were encoded as JSON strings. So trying to decode the plain string field with JSON decoder would no doubt fail since it is not a valid JSON string.
You need to find what JSON is actually being parsed. Run the application within a debugger, set a breakpoint on the relevant constructor for JsonParseException … then find out what is in the ByteArrayInputStream that it is attempting to parse