Note: this is a follow-up to this question.
I am developing a website that allows users to upload large chunks of data to my Java backend. Once validated, the data must be stored on disk. Here, "large" means in the order of 10 KB up to 100 KB.
Given that a large number of users can submit large chunks of data at the same time, and that the data must first be analyzed (validated) before being stored on disk on the server side, what options do I have to prevent JVM out-of-memory errors while processing the data chunks? Note that each data chunk is received at the moment from the frontend in a String
object.