I'm uploading multiple files to Amazon S3 using Java. The code I'm using is as follows: MultipartHttpServletRequest multipartRequest = (MultipartHttpServletRequest) request; MultiValueMap < String, MultipartFile > map = multipartRequest.getMultiFileMap(); try { if (map != null) { for (String filename: map.keySet()) { List < MultipartFile > fileList = map.get(filename); incrPercentge = 100 / fileLi