I have method for multipart request
@RequestMapping(method = RequestMethod.POST)
public @ResponseBody ResponseEntity<Photo> updatePhoto(@RequestHeader(value="Access-key") String accessKey,
@RequestHeader(value="Secret-key") String secretKey,
@PathVariable("file") MultipartFile file)
When I test it in postman without content-type:multipart/form-data header it works when with it I get
org.springframework.web.util.NestedServletException: Request processing failed; nested exception is org.springframework.web.multipart.MultipartException: Could not parse multipart servlet request; nested exception is org.apache.commons.fileupload.FileUploadException: the request was rejected because no multipart boundary was found
Why it happens?