How i can set up compression level for zstd encode type?
I make tests with zstd, zstd 6, zstd 11 and have same results with dile size.
In klauspost/compress (with hints from this forum post by @francislavoie ) i found levels in text notaion, but zstd best has no effect again.
Caddy version:
v2.7.6
System environment:
Ubuntu 22.04.4 LTS
My complete Caddy config:
website.ltd {
#...
encode {
#has no effect this variants:
#zstd best
#zstd 6
zstd
br 6
gzip 6
}
#...
}
P.S. Thanks for awesomeness to all Caddy team and forum activists!
Please completely fill out the help topic template as per the forum rules.
What did you try exactly? What’s your evidence that it’s not working? Show an example request with curl -v. Enable the debug global option. Show your Caddy logs.
Hi and thanks for quick answer. Sorry but i cant fill up help template more relevant info. i am new caddy user and many simple manipulations (log enable and more) are difficult to me. In addition, my fresh installed windows 11 curl said me curl: option --compressed: the installed libcurl version doesn't support this, and without this flag curl’s report not relevant to my tests.
But i have fresh Chrome (v122.0.6261.95) browser with zstd support (and even enabled additional manually with chrome://flags/#enable-zstd-content-encoding before and after repeate tests) and its inspector info much representative for me, see my compilation of screenshots on one image(cant embed image bacause of new user’s forum restrictions)
And this is comparison with brotli levels (whith works perfect), see results below/
Can you or anyone tell me if specifying the compression level for zstd should have an effect at all or if the level cannot be adjusted?
I tested the different settings that I specified above and checked the actual size of the compressed data through Chrome inspector. The compression level in all cases is approximately equal to brotli 5.
Unfortunately, I did not take screenshots and logs, as I thought that confirmation of the problem would not be necessary. in none of the caddy documentation examples did I find an explicit indication of the compression level, so is this possible or not?
Thanks for info. Since Chrome added zstd for desktop browsers by default (caniuse says about flag-enabled for v121 and 122 and without flags on v123+, but we see default support in real even on Chrome v121, and it means we can serve zstd to about 20% users), but broli level 6 is faster and we need zstd compression adjustment to be on the edge
If i can help (with github issue star or another way, beta test maybe) please let me know!