Describe the bug Please provide details of the problem, including the version of Spring Cloud that you are using.
@GetMapping(value = ApiConst.UpcController.downloadTemplate.PATH,
consumes = MediaType.APPLICATION_FORM_URLENCODED_VALUE,
produces = MediaType.APPLICATION_OCTET_STREAM_VALUE)
ResponseEntity<StreamingResponseBody> downloadTemplate()
error here
@SuppressWarnings("ConstantConditions")
public boolean hasEmptyMessageBody() throws IOException {
InputStream body = this.response.getBody();
// Per contract body shouldn't be null, but check anyway..
if (body == null) {
return true;
}
if (body.markSupported()) {
body.mark(1);
if (body.read() == -1) {
return true;
}
else {
body.reset();
return false;
}
}
else {
this.pushbackInputStream = new PushbackInputStream(body);
int b = this.pushbackInputStream.read();
if (b == -1) {
return true;
}
else {
this.pushbackInputStream.unread(b);
return false;
}
}
}
this.pushbackInputStream.read() Method threw 'java.io.IOException' exception. stream is closed
why ? feign is not spport produces application/octet-stream ?
Comment From: OlgaMaciaszek
Hello @lnsane, please provide a minimal, complete, verifiable example that reproduces the issue.
Comment From: spring-cloud-issues
If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.
Comment From: spring-cloud-issues
Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.