If I accept a file from a MultipartRequest and call
File f = request.getFile("fileName");
Is the file written to disk (as a temp file) or is it only stored in memory at this point?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Assuming you’re talking about the o’Reilly MultipartRequest it’ll always be written to disk according to the link.
Update
If you’re talking about the Spring commons FileUpload component, it does support this setup. One of the properties you can set is
setMaxInMemorySize(int bytes)which determines the max size of a file that will be held in memory and not written to disk.