Skip to content

3.0.3

Latest

Choose a tag to compare

@github-actions github-actions released this 01 Nov 14:50
· 1 commit to main since this release
b4c9ed9

New

  • Configurable keep-alive idle timeout. A connection with no new request closes after idleTimeout. The default stays 30 seconds.

    Behind a load balancer, set it longer than the balancer's idle timeout. For example, AWS ALB keeps connections for 60 seconds, so use 65. Otherwise the server may close a connection the balancer still uses, and clients get 502.

    NativeHttpServer server = await NativeHttpServer.bind(
      3000,
      idleTimeout: Duration(seconds: 65),
    );

Fixes (with autoCompress on)

  • Answers that could be gzipped now send Vary: Accept-Encoding. A shared cache no longer gives a gzip body to a client that can not read it.
  • Accept-Encoding: gzip;q=0 now means "no gzip".
  • Files that are compressed already (images, audio, video, zip, woff and so on) are no longer gzipped again. This saves CPU. image/svg+xml is still gzipped.

Good to know

  • Native ABI 9. The build hook downloads the new library for you.
  • The idleTimeout field now shows the value given to bind. Setting it later still has no effect, and it stays deprecated.

Full list: the CHANGELOG.

Ready-built dox_http_native libraries. See SHA256SUMS.