Oszczędności
Zastosowanie kompresji gzip powoduje ogólne zmniejszenie odsyłanej klientowi odpowiedzi o około 70%. W Tabela 6-2 zostały przedstawione przykładowe wielkości skryptów oraz arkuszy stylów (małego i dużego) przed i po kompresji.
Tabela 6-2. Porównanie wielkości danych skompresowanych za pomocą gzip i deflate
Rodzaj pliku |
Bez kompresji |
Kompresja gzip |
Oszczędność |
Kompresja deflate |
Oszczędność |
---|---|---|---|---|---|
Skrypt |
3277 bajtów |
1076 bajtów |
67% |
1112 bajtów |
66% |
Skrypt (duży) |
39 713 bajtów |
14 488 bajtów |
64% |
16 583 bajty |
58% |
Arkusz stylów |
968 bajtów |
426 bajtów |
56% |
463 bajty |
52% |
Arkusz stylów (duży) |
14 122 bajty |
3748 bajtów |
73% |
4665 bajtów |
67% |
Z Tabela 6-2 wyraźnie wynika, że format gzip jest efektywniejszą metodą kompresji. Użycie metody gzip powoduje ...
Get Wydajne witryny internetowe. Przyspieszanie działania serwisów WWW now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.