=encoding utf-8 =head1 NAME ngx_http_slice_module - Module ngx_http_slice_module =head1 The C module (1.9.8) is a filter that splits a request into subrequests, each returning a certain range of response. The filter provides more effective caching of big responses. This module is not built by default, it should be enabled with the C<--with-http_slice_module> configuration parameter. =head1 Example Configuration location / { slice 1m; proxy_cache cache; proxy_cache_key $uri$is_args$args$slice_range; proxy_set_header Range $slice_range; proxy_cache_valid 200 206 1h; proxy_pass http://localhost:8000; } In this example, the response is split into 1-megabyte cacheable slices. =head1 Directives =head2 slice B slice I> B I<0> B I B I B I Sets the I> of the slice. The zero value disables splitting responses into slices. Note that a too low value may result in excessive memory usage and a large number of file descriptors. In order for a subrequest to return the required range, the C<$slice_range> variable should be L to the proxied server as the C request header field. If L is enabled, C<$slice_range> should be added to the L and caching of responses with 206 status code should be L. =head1 Embedded Variables The C module supports the following embedded variables: =over =item C<$slice_range> the current slice range in L format, for example, C. =back