Sending multiple files to a servlet with a single connection
问题 I'm writing a Java desktop client which will send multiple files over the wire to a servlet using a post request. In the servlet I'm getting the input stream from the request to receive the files. The servlet will write the files to disk, one by one as they're read from the stream. The implementation has a couple of requirements: Only one HTTP request must be used to the server (so only a single stream) The servlet must use a reasonable fixed amount of memory, no matter what the size of the