gzip_types

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

gzip_types

Friscia, Michael

What would be the reason that setting

Gzip_types *;

Is bad?

 

I’m running into a compression problem and if I set it to * everything gzips just fine but if I list them out explicitly the type image/jpeg is not being gzip’d via proxy request but all others are gzip’d by proxy. Gzip_proxied is set to any.

 

___________________________________________

Michael Friscia

Office of Communications

Yale School of Medicine

(203) 737-7932 - office

(203) 931-5381 - mobile

http://web.yale.edu

 


_______________________________________________
nginx mailing list
[hidden email]
http://mailman.nginx.org/mailman/listinfo/nginx
Reply | Threaded
Open this post in threaded view
|

Re: gzip_types

Maxim Dounin
Hello!

On Thu, Aug 23, 2018 at 11:21:02AM +0000, Friscia, Michael wrote:

> What would be the reason that setting
> Gzip_types *;
> Is bad?

Usually there are responses which are not compressible, so trying
to gzip them is just a waste of resources.  Also there can be
cases when the client announces gzip support, but in fact have
problems when some types of responses are compressed - for
example, there were problems with compressed javascripts in some
browsers in the past.

If you are sure that in a particular configuration all possible
responses must be gzipped, "gzip_types *;" should be fine.  You
may want to limit it to a particular location or server though.

> I’m running into a compression problem and if I set it to *
> everything gzips just fine but if I list them out explicitly the
> type image/jpeg is not being gzip’d via proxy request but all
> others are gzip’d by proxy. Gzip_proxied is set to any.

As long as Content-Type of the response is "image/jpeg", there
should be not difference between "gzip_types *" and "gzip_types
image/jpeg ...".  If you see a difference, please provide more
details - full configuration and a debug log would be ideal.

--
Maxim Dounin
http://mdounin.ru/
_______________________________________________
nginx mailing list
[hidden email]
http://mailman.nginx.org/mailman/listinfo/nginx
Reply | Threaded
Open this post in threaded view
|

Re: gzip_types

Friscia, Michael
Thank you for that explanation. I'm still debugging this with our CDN vendor. They have identified a number of bugs on their end which explain the odd behavior I've been seeing.

___________________________________________
Michael Friscia
Office of Communications
Yale School of Medicine
(203) 737-7932 - office
(203) 931-5381 - mobile
http://web.yale.edu <http://web.yale.edu/>
 

On 8/23/18, 2:00 PM, "nginx on behalf of Maxim Dounin" <[hidden email] on behalf of [hidden email]> wrote:

    Hello!
   
    On Thu, Aug 23, 2018 at 11:21:02AM +0000, Friscia, Michael wrote:
   
    > What would be the reason that setting
    > Gzip_types *;
    > Is bad?
   
    Usually there are responses which are not compressible, so trying
    to gzip them is just a waste of resources.  Also there can be
    cases when the client announces gzip support, but in fact have
    problems when some types of responses are compressed - for
    example, there were problems with compressed javascripts in some
    browsers in the past.
   
    If you are sure that in a particular configuration all possible
    responses must be gzipped, "gzip_types *;" should be fine.  You
    may want to limit it to a particular location or server though.
   
    > I’m running into a compression problem and if I set it to *
    > everything gzips just fine but if I list them out explicitly the
    > type image/jpeg is not being gzip’d via proxy request but all
    > others are gzip’d by proxy. Gzip_proxied is set to any.
   
    As long as Content-Type of the response is "image/jpeg", there
    should be not difference between "gzip_types *" and "gzip_types
    image/jpeg ...".  If you see a difference, please provide more
    details - full configuration and a debug log would be ideal.
   
    --
    Maxim Dounin
    https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fmdounin.ru%2F&amp;data=02%7C01%7Cmichael.friscia%40yale.edu%7C6c5e1fd929a949e6066108d609224e47%7Cdd8cbebb21394df8b4114e3e87abeb5c%7C0%7C0%7C636706440293411790&amp;sdata=cjPwik9wTdi0Wpw0InRg9zlE2lvOY3ejsvkvlhBO4f8%3D&amp;reserved=0
    _______________________________________________
    nginx mailing list
    [hidden email]
    https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fmailman.nginx.org%2Fmailman%2Flistinfo%2Fnginx&amp;data=02%7C01%7Cmichael.friscia%40yale.edu%7C6c5e1fd929a949e6066108d609224e47%7Cdd8cbebb21394df8b4114e3e87abeb5c%7C0%7C0%7C636706440293411790&amp;sdata=Vjpk7hlLViXxOIXo2Tav57J%2FcgRyA6fI5ppkDzs6E18%3D&amp;reserved=0

_______________________________________________
nginx mailing list
[hidden email]
http://mailman.nginx.org/mailman/listinfo/nginx