Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable transport compression for backend API #667

Open
Rotzbua opened this issue Apr 13, 2023 · 0 comments
Open

Enable transport compression for backend API #667

Rotzbua opened this issue Apr 13, 2023 · 0 comments

Comments

@Rotzbua
Copy link
Contributor

Rotzbua commented Apr 13, 2023

Problem

The API does not compress the (json) response. This leads to high traffic and increased loading times.

Example

Statistics URL: https://w3champions.com/OverallStatistics/

API Requests:

Source test result:
https://pagespeed.web.dev/analysis/https-w3champions-com-OverallStatistics/7jpdz9z2je?form_factor=mobile

Possible solution

A) Enable compression at the proxy

networks:
default:
external:
name: nginx-proxy

Remove compression by frontend container: https://github.com/w3champions/website/blob/master/gzip.conf

B) Use Cloudflare (uses compression by default)

Reference

https://developer.chrome.com/docs/lighthouse/performance/uses-text-compression/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant