Consider a huge JSON with a structure like -
{"text": "very HUGE text here.."}
I save this JSON as an object ObjectNodecalled say json.
Now I am trying to extract this text from ObjectNode.
String text = json.get("text").asText()
This JSON can be 4-5 MB in size. When I run this code, I do not get the result (the program continues to run forever).
The above method works fine for small and normal size strings. Is there any other best practice for retrieving huge data from JSON?
source
share