wodby / nginx

Nginx docker container image
https://wodby.com/stacks
MIT License
72 stars 51 forks source link

default NGINX_BROTLI_COMP_LEVEL to big #40

Open Punk-UnDeaD opened 4 years ago

Punk-UnDeaD commented 4 years ago

I think level 6 - not best idea. It slower than gzip, also i can't use brotli_static and gzip together for static files. I runed some tests and think than 2 - better level by default, response smaller than gziped and nginx work fast.

csandanov commented 4 years ago

Hi, I agree we should set it lower because our default gzip comp level is currently 1. I would say we should also set it to 1, further optimizations depend on the CPU resources and the nature of the content.

Ref:

If we want to set it higher, brotli should be 5 (to enable context modeling) but gzip in this case should probably be around 8-9.