70.20 Enable HTTP response compression

HTTP response compression is supported by Jetty, Tomcat, and Undertow. It can be enabled via application.properties:

server.compression.enabled=true

By default, responses must be at least 2048 bytes in length for compression to be performed. This can be configured using the server.compression.min-response-size property.

By default, responses will only be compressed if their content type is one of the following:

  • text/html
  • text/xml
  • text/plain
  • text/css

This can be configured using the server.compression.mime-types property.

results matching ""

    No results matching ""