I use Spring to call a REST API which reply with header that contains "Content-Type: multipart/mixed; boundary==_123456789".
My problem is that Spring try to parse the Content-Type and throw InvalidMediaTypeException due to '=' in boundary token.
Is there a way to disable this checking (or any workaround) ?
These are my logs :
org.springframework.http.InvalidMediaTypeException: Invalid mime type "multipart/mixed; boundary==_11204303fda4403b6a72d61500081354": Invalid token character '=' in token "=_11204303fda4403b6a72d61500081354"
at org.springframework.http.MediaType.parseMediaType(MediaType.java:620)
at org.springframework.http.HttpHeaders.getContentType(HttpHeaders.java:992)
at org.springframework.web.client.HttpMessageConverterExtractor.getContentType(HttpMessageConverterExtractor.java:136)
at org.springframework.web.client.HttpMessageConverterExtractor.extractData(HttpMessageConverterExtractor.java:93)
at org.springframework.web.client.RestTemplate$ResponseEntityResponseExtractor.extractData(RestTemplate.java:1037)
at org.springframework.web.client.RestTemplate$ResponseEntityResponseExtractor.extractData(RestTemplate.java:1020)
at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:778)
at org.springframework.web.client.RestTemplate.execute(RestTemplate.java:711)
at org.springframework.web.client.RestTemplate.postForEntity(RestTemplate.java:468)