After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 666623 - Add gzip encoding support
Add gzip encoding support
Status: RESOLVED FIXED
Product: libgdata
Classification: Platform
Component: General
git master
Other All
: Normal enhancement
: 0.16
Assigned To: libgdata-maint
libgdata-maint
Depends on:
Blocks:
 
 
Reported: 2011-12-21 00:02 UTC by Philip Withnall
Modified: 2014-08-24 16:17 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
core: Add gzip encoding support (2.47 KB, patch)
2014-08-24 16:16 UTC, Philip Withnall
committed Details | Review

Description Philip Withnall 2011-12-21 00:02:41 UTC
Apparently all of the Google APIs support gzip encoding of responses if we set the appropriate request headers.

http://googleappsdeveloper.blogspot.com/2011/12/optimizing-bandwidth-usage-with-gzip.html
Comment 1 Philip Withnall 2014-08-24 16:16:09 UTC
Created attachment 284351 [details] [review]
core: Add gzip encoding support

libsoup already transparently supported gzip encoding of data from the
server, using SoupContentDecoder, which is present by default in a
SoupSession. We were correctly sending the Accept-Encoding header, but
Google also require that the string ‘gzip’ be present in the User-Agent
header to enable gzip support.

Add a User-Agent header which supports this.
Comment 2 Philip Withnall 2014-08-24 16:17:05 UTC
This was pleasingly simple to implement!

Attachment 284351 [details] pushed as 6e89b03 - core: Add gzip encoding support