mirror of
https://github.com/h2o/h2o.git
synced 2025-05-31 18:17:34 +08:00
Merge pull request #3481
Renamed file extension for zstd | .zstd > .zst
This commit is contained in:
commit
f1918a5b9f
doc
lib/handler
srcdoc/configure
t
@ -445,7 +445,7 @@ A flag indicating how a pre-compressed file should be served.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
If set to <code>ON</code>, the handler looks for a file with <code>.br</code>, <code>.zstd</code>, or <code>.gz</code> appended and sends the file, if the client is capable of transparently decoding a <a href="https://www.rfc-editor.org/rfc/rfc7932.html" target=_blank>brotli</a>, <a href="https://www.rfc-editor.org/rfc/rfc8878.html" target=_blank>zstd</a>, or <a href="https://tools.ietf.org/html/rfc1952" target=_blank>gzip</a>-encoded response.
|
||||
If set to <code>ON</code>, the handler looks for a file with <code>.br</code>, <code>.zst</code>, or <code>.gz</code> appended and sends the file, if the client is capable of transparently decoding a <a href="https://www.rfc-editor.org/rfc/rfc7932.html" target=_blank>brotli</a>, <a href="https://www.rfc-editor.org/rfc/rfc8878.html" target=_blank>zstd</a>, or <a href="https://tools.ietf.org/html/rfc1952" target=_blank>gzip</a>-encoded response.
|
||||
For example, if a client requests a file named <code>index.html</code> with <code>Accept-Encoding: gzip</code> header and if <code>index.html.gz</code> exists, the <code>.gz</code> file is sent as a response together with a <code>Content-Encoding: gzip</code> response header.
|
||||
When both the client and the server support multiple content encodings, the encoding chosen is the first one listed in the following order: brotli, zstd, gzip.
|
||||
</p>
|
||||
|
@ -3112,7 +3112,7 @@ A flag indicating how a pre-compressed file should be served.
|
||||
.PP
|
||||
|
||||
|
||||
If set to ON, the handler looks for a file with .br, .zstd, or .gz appended and sends the file, if the client is capable of transparently decoding a brotli, zstd, or gzip-encoded response.
|
||||
If set to ON, the handler looks for a file with .br, .zst, or .gz appended and sends the file, if the client is capable of transparently decoding a brotli, zstd, or gzip-encoded response.
|
||||
For example, if a client requests a file named index.html with Accept-Encoding: gzip header and if index.html.gz exists, the .gz file is sent as a response together with a Content-Encoding: gzip response header.
|
||||
When both the client and the server support multiple content encodings, the encoding chosen is the first one listed in the following order: brotli, zstd, gzip.
|
||||
|
||||
|
File diff suppressed because one or more lines are too long
@ -353,8 +353,11 @@ static struct st_h2o_sendfile_generator_t *create_generator(h2o_req_t *req, cons
|
||||
} \
|
||||
}
|
||||
TRY_VARIANT(H2O_COMPRESSIBLE_BROTLI, "br", ".br");
|
||||
TRY_VARIANT(H2O_COMPRESSIBLE_ZSTD, "zstd", ".zstd");
|
||||
TRY_VARIANT(H2O_COMPRESSIBLE_ZSTD, "zstd", ".zst");
|
||||
TRY_VARIANT(H2O_COMPRESSIBLE_GZIP, "gzip", ".gz");
|
||||
|
||||
// Deprecated
|
||||
TRY_VARIANT(H2O_COMPRESSIBLE_ZSTD, "zstd", ".zstd");
|
||||
#undef TRY_VARIANT
|
||||
}
|
||||
}
|
||||
|
@ -239,7 +239,7 @@ EOT
|
||||
)->(sub {
|
||||
?>
|
||||
<p>
|
||||
If set to <code>ON</code>, the handler looks for a file with <code>.br</code>, <code>.zstd</code>, or <code>.gz</code> appended and sends the file, if the client is capable of transparently decoding a <a href="https://www.rfc-editor.org/rfc/rfc7932.html" target=_blank>brotli</a>, <a href="https://www.rfc-editor.org/rfc/rfc8878.html" target=_blank>zstd</a>, or <a href="https://tools.ietf.org/html/rfc1952" target=_blank>gzip</a>-encoded response.
|
||||
If set to <code>ON</code>, the handler looks for a file with <code>.br</code>, <code>.zst</code>, or <code>.gz</code> appended and sends the file, if the client is capable of transparently decoding a <a href="https://www.rfc-editor.org/rfc/rfc7932.html" target=_blank>brotli</a>, <a href="https://www.rfc-editor.org/rfc/rfc8878.html" target=_blank>zstd</a>, or <a href="https://tools.ietf.org/html/rfc1952" target=_blank>gzip</a>-encoded response.
|
||||
For example, if a client requests a file named <code>index.html</code> with <code>Accept-Encoding: gzip</code> header and if <code>index.html.gz</code> exists, the <code>.gz</code> file is sent as a response together with a <code>Content-Encoding: gzip</code> response header.
|
||||
When both the client and the server support multiple content encodings, the encoding chosen is the first one listed in the following order: brotli, zstd, gzip.
|
||||
</p>
|
||||
|
@ -77,7 +77,7 @@ EOT
|
||||
my $index_orig_len = (stat 't/assets/doc_root/index.txt')[7];
|
||||
my $index_gz_len = (stat 't/assets/doc_root/index.txt.gz')[7];
|
||||
my $index_br_len = (stat 't/assets/doc_root/index.txt.br')[7];
|
||||
my $index_zstd_len = (stat 't/assets/doc_root/index.txt.zstd')[7];
|
||||
my $index_zstd_len = (stat 't/assets/doc_root/index.txt.zst')[7];
|
||||
my $alice2_orig_len = `gzip -cd < t/assets/doc_root/alice2.txt.gz | wc -c`;
|
||||
my $alice2_gz_len = (stat 't/assets/doc_root/alice2.txt.gz')[7];
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user