Solved

Gzip performance

Posted on 2014-02-01
4
359 Views
Last Modified: 2014-02-02
When I run the audit of chrome it says:

Compressing the following resources with gzip could reduce their transfer size by about two thirds (~58.3¿KB):

Do you believe does  it worth to make a necessary change? If I do it do the users will feel the difference?

Thank you
0
Comment
Question by:myyis
  • 2
4 Comments
 
LVL 83

Accepted Solution

by:
Dave Baldwin earned 250 total points
ID: 39826706
That is probably Not what you think it is.  It does not mean that You should Gzip the files but that the server should Gzip the transmission if the browser puts 'gzip' in it's 'accept' line in the request headers.  You can go to this site to see if your server is providing compression when requested: http://www.whatsmyip.org/http-compression-test/   If it is Not, then you have to tell the server to do it.  Gzipping the files yourself will just confuse the process.
0
 

Author Comment

by:myyis
ID: 39826710
I did the test,
says  "is NOT Compressed"

Page Size: 82.3 KB
Compressed Page Size: 22.4 KB
Potential Savings: 72.8%
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 39826714
I suggest you contact your hosting company and ask them to enable compression.  Apache and IIS web servers have different methods of doing that.
0
 
LVL 34

Assisted Solution

by:gr8gonzo
gr8gonzo earned 250 total points
ID: 39826786
Like Dave mentioned, gzip compression on web pages means something a little different. Basically, after the HTML (or whatever content) is loaded up into memory, the web server can then compress the contents and THEN send the compressed version to the browser. Almost all modern browsers have the ability do decompress the data and then handle the normal, decompressed stuff as if the compression had never happened.

There are two common downsides to gzip compression on web pages:

1. It eats up a little bit of CPU on the server because it requires the CPU to run the compression algorithms before the data can be sent.

2. Compression requires the ENTIRE page to finish being generated on the server before it can start (because compression is about analyzing the full contents to figure out the best way of compressing it), and it also requires the FULL file to be downloaded before decompression can start, so this means you can't stream gzipped compressed content. It has to finish loading, finish compressing, finish downloading, and finish decompressing before the browser sees any HTML at all.

Of course, if you have any bandwidth limitations on your account, then compression can definitely help you conserve that bandwidth (which is also usually good for the internet as a whole, too).
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Author Note: Since this E-E article was originally written, years ago, formal testing has come into common use in the world of PHP.  PHPUnit (http://en.wikipedia.org/wiki/PHPUnit) and similar technologies have enjoyed wide adoption, making it possib…
These days socially coordinated efforts have turned into a critical requirement for enterprises.
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
The viewer will learn how to count occurrences of each item in an array.

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now