Class ConfiguredGZipEncoder

java.lang.Object
io.dropwizard.jersey.gzip.ConfiguredGZipEncoder
All Implemented Interfaces:
jakarta.ws.rs.client.ClientRequestFilter, jakarta.ws.rs.ext.WriterInterceptor

@Provider @Priority(4000) public class ConfiguredGZipEncoder extends Object implements jakarta.ws.rs.ext.WriterInterceptor, jakarta.ws.rs.client.ClientRequestFilter
GZIP encoding support. Writer interceptor that encodes the output if Content-Encoding header value equals to gzip or x-gzip. If so configured, it will encode the output even if the gzip and x-gzip Content-Encoding header is missing, and insert a value of gzip for that header.
  • Constructor Details

    • ConfiguredGZipEncoder

      public ConfiguredGZipEncoder(boolean forceEncoding)
  • Method Details

    • filter

      public void filter(jakarta.ws.rs.client.ClientRequestContext context) throws IOException
      Specified by:
      filter in interface jakarta.ws.rs.client.ClientRequestFilter
      Throws:
      IOException
    • aroundWriteTo

      public final void aroundWriteTo(jakarta.ws.rs.ext.WriterInterceptorContext context) throws IOException
      Specified by:
      aroundWriteTo in interface jakarta.ws.rs.ext.WriterInterceptor
      Throws:
      IOException