{"id":14598,"date":"2022-09-30T15:13:23","date_gmt":"2022-09-30T15:13:23","guid":{"rendered":"http:\/\/www.max-sperling.bplaced.net\/?p=14598"},"modified":"2024-02-16T10:44:22","modified_gmt":"2024-02-16T10:44:22","slug":"compressed-download-http","status":"publish","type":"post","link":"http:\/\/www.max-sperling.bplaced.net\/?p=14598","title":{"rendered":"Compressed download (HTTP)"},"content":{"rendered":"<p>There are two ways to transmit compressed data via HTTP: Content-Encoding and Transfer-Encoding.<\/p>\n<hr>\n<table>\n<colgroup>\n<col style=\"width: 30%;\">\n<col style=\"width: 35%;\">\n<col style=\"width: 35%;\">\n  <\/colgroup>\n<tr>\n<th><\/th>\n<th>Content-Encoding<\/th>\n<th>Transfer-Encoding<\/th>\n<\/tr>\n<tr>\n<th>Request header<\/th>\n<td>Accept-Encoding: {algorithms}<\/td>\n<td>TE: {algorithms}<\/td>\n<\/tr>\n<tr>\n<th>Response header<\/th>\n<td>Content-Encoding: {algorithms}<\/td>\n<td>Transfer-Encoding: {algorithms}<\/td>\n<\/tr>\n<tr>\n<th>Influencer<\/th>\n<td>Client and Server<\/td>\n<td>Every node<sup>1<\/sup><\/td>\n<\/tr>\n<tr>\n<th>Supported \/ Used<\/th>\n<td>Widely<\/td>\n<td>Rarely<\/td>\n<\/tr>\n<tr>\n<th>Pre-computed<\/th>\n<td>Likely<\/td>\n<td>No<\/td>\n<\/tr>\n<tr>\n<th>&#8216;Content-Length&#8217; \/ &#8216;Ranges&#8217; relates to<\/th>\n<td>&#8230; the compressed file<\/td>\n<td>&#8230; the uncompressed file<\/td>\n<\/tr>\n<\/table>\n<hr>\n<p><sup>1<\/sup> Every node in between can add \/ remove compression.<\/p>\n<pre>\r\nClient       Proxy1                      Proxy2       Server\r\n  |            |                           |            |\r\n  |----------->|                           |            |\r\n  |HTTP GET    |                           |            |\r\n  |            |-------------------------->|            |\r\n  |            |HTTP GET                   |            |\r\n  |            |TE: gzip                   |----------->|\r\n  |            |                           |HTTP GET    |\r\n  |            |                           |            |\r\n  |            |                           |<-----------|\r\n  |            |                           |    HTTP 200|\r\n  |            |<--------------------------|            |\r\n  |            |                   HTTP 200|            |\r\n  |<-----------|    Transfer-Encoding: gzip|            |\r\n  |    HTTP 200|                           |            |\r\n  |            |                           |            |\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>There are two ways to transmit compressed data via HTTP: Content-Encoding and Transfer-Encoding. Content-Encoding Transfer-Encoding Request header Accept-Encoding: {algorithms} TE:<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"inline_featured_image":false},"categories":[55],"tags":[],"_links":{"self":[{"href":"http:\/\/www.max-sperling.bplaced.net\/index.php?rest_route=\/wp\/v2\/posts\/14598"}],"collection":[{"href":"http:\/\/www.max-sperling.bplaced.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.max-sperling.bplaced.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.max-sperling.bplaced.net\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.max-sperling.bplaced.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=14598"}],"version-history":[{"count":1,"href":"http:\/\/www.max-sperling.bplaced.net\/index.php?rest_route=\/wp\/v2\/posts\/14598\/revisions"}],"predecessor-version":[{"id":16826,"href":"http:\/\/www.max-sperling.bplaced.net\/index.php?rest_route=\/wp\/v2\/posts\/14598\/revisions\/16826"}],"wp:attachment":[{"href":"http:\/\/www.max-sperling.bplaced.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=14598"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.max-sperling.bplaced.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=14598"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.max-sperling.bplaced.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=14598"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}