Note: That this is NOT feign.compression. response. enabled : true in my question,but feign.compression.request.enabled: true.

Previous issues aboult the same topic: https://github.com/spring-cloud/spring-cloud-openfeign/issues/635 https://github.com/spring-cloud/spring-cloud-openfeign/issues/639

Client is openfeign 10.10(apache httpclient4.5.13 in classpath), server is springboot2.3 When I debugged, I found that the request body was not compressed, but just added a header. I guessed that httpclient would compress the request body according to the header(Content-Encoding:gzip), but I didn't find the corresponding class.

So my question is: Does this configuration(feign.compression. response. enabled : true) only add a header(Content-Encoding:gzip), or does it need a specific library in classpath to compression request?

org.springframework.cloud.openfeign.encoding.FeignContentGzipEncodingInterceptor:

public void apply(RequestTemplate template) {
     if (requiresCompression(template)) {
         addHeader(template, HttpEncoding.CONTENT_ENCODING_HEADER,HttpEncoding.GZIP_ENCODING, HttpEncoding.DEFLATE_ENCODING);
    }
}

Plus,sorry for opening 3 issues about the topic,and could you close the issue later until the problem is over. Thanks.

Comment From: OlgaMaciaszek

Duplicate of #639.