Prefer maximum compression on compressed requests

We have many clients and a single server, pushing additional work at the clients will typically degrade the effective speed with which the data can be transmitted, but will allow our server to handle more requests concurrently due to less bandwidth used, and will positively affect the bandwidth used for both server and the client.
This commit is contained in:
Archi
2023-01-31 22:19:41 +01:00
parent d4efe537d9
commit 17d9c9bc22

View File

@@ -60,9 +60,9 @@ internal static class WebBrowserUtilities {
ArgumentNullException.ThrowIfNull(output);
#if NETFRAMEWORK
return (new GZipStream(output, CompressionLevel.Fastest, true), "gzip");
return (new GZipStream(output, CompressionLevel.Optimal, true), "gzip");
#else
return (new BrotliStream(output, CompressionLevel.Fastest, true), "br");
return (new BrotliStream(output, CompressionLevel.SmallestSize, true), "br");
#endif
}
}