view xml/en/docs/http/ngx_http_mirror_module.xml @ 2087:4931a7ba6a32

Restored proper tense in limit_conn description. The limit_conn module only limits connections with active requests, that is, if a connection has a request "being processed" by the server. During a text review in 95c3c3bbf1ce it was changed to "has a request processed", which is incorrect (it is true after processing the first request). Reported by Abilio Marques, http://mailman.nginx.org/pipermail/nginx/2017-December/055322.html.
author Maxim Dounin <mdounin@mdounin.ru>
date Tue, 19 Dec 2017 20:49:06 +0300
parents 1fe9f481d8ce
children 5cacd6fffade
line wrap: on
line source

<?xml version="1.0"?>

<!--
  Copyright (C) Nginx, Inc.
  -->

<!DOCTYPE module SYSTEM "../../../../dtd/module.dtd">

<module name="Module ngx_http_mirror_module"
        link="/en/docs/http/ngx_http_mirror_module.html"
        lang="en"
        rev="2">

<section id="summary">

<para>
The <literal>ngx_http_mirror_module</literal> module (1.13.4) implements
mirroring of an original request
by creating background mirror subrequests.
Responses to mirror subrequests are ignored.
</para>

</section>


<section id="example" name="Example Configuration">

<para>
<example>
location / {
    mirror /mirror;
    proxy_pass http://backend;
}

location /mirror {
    internal;
    proxy_pass http://test_backend$request_uri;
}
</example>
</para>

</section>


<section id="directives" name="Directives">

<directive name="mirror">
<syntax><value>uri</value> | <literal>off</literal></syntax>
<default>off</default>
<context>http</context>
<context>server</context>
<context>location</context>

<para>
Sets the URI to which an original request will be mirrored.
Several mirrors can be specified on the same level.
</para>

</directive>


<directive name="mirror_request_body">
<syntax><literal>on</literal> | <literal>off</literal></syntax>
<default>on</default>
<context>http</context>
<context>server</context>
<context>location</context>

<para>
Indicates whether the client request body is mirrored.
When enabled, the client request body will be read
prior to creating mirror subrequests.
In this case, unbuffered client request body proxying
set by the
<link doc="ngx_http_proxy_module.xml" id="proxy_request_buffering"/>,
<link doc="ngx_http_fastcgi_module.xml" id="fastcgi_request_buffering"/>,
<link doc="ngx_http_scgi_module.xml" id="scgi_request_buffering"/>,
and
<link doc="ngx_http_uwsgi_module.xml" id="uwsgi_request_buffering"/>
directives will be disabled.
<example>
location / {
    mirror /mirror;
    mirror_request_body off;
    proxy_pass http://backend;
}

location /mirror {
    internal;
    proxy_pass http://log_backend;
    proxy_pass_request_body off;
    proxy_set_header Content-Length "";
    proxy_set_header X-Original-URI $request_uri;
}
</example>
</para>

</directive>

</section>

</module>