annotate xml/ru/docs/http/ngx_http_upstream_hc_module.xml @ 1946:37df1535ea91

Moved info from http "health_check" and "match" to intro.
author Yaroslav Zhuravlev <yar@nginx.com>
date Thu, 30 Mar 2017 21:26:44 +0300
parents 88477c5d2751
children 8f9c685dfabd
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
222
bfe3eff81d04 Removed redundant encoding specification.
Ruslan Ermilov <ru@nginx.com>
parents: 135
diff changeset
1 <?xml version="1.0"?>
76
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
2
580
be54c443235a Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents: 566
diff changeset
3 <!--
be54c443235a Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents: 566
diff changeset
4 Copyright (C) Nginx, Inc.
be54c443235a Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents: 566
diff changeset
5 -->
be54c443235a Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents: 566
diff changeset
6
76
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
7 <!DOCTYPE module SYSTEM "../../../../dtd/module.dtd">
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
8
1945
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
9 <module name="Модуль ngx_http_upstream_hc_module"
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
10 link="/ru/docs/http/ngx_http_upstream_hc_module.html"
589
764fbac1b8b4 Added document revision.
Ruslan Ermilov <ru@nginx.com>
parents: 580
diff changeset
11 lang="ru"
1946
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
12 rev="2">
76
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
13
110
40eec261c2a6 Added proper support for anonymous sections, notably for the summary.
Ruslan Ermilov <ru@nginx.com>
parents: 108
diff changeset
14 <section id="summary">
76
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
15
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
16 <para>
1945
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
17 Модуль <literal>ngx_http_upstream_hc_module</literal>
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
18 позволяет активировать периодические проверки работоспособности серверов в
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
19 <link doc="ngx_http_upstream_module.xml" id="upstream">группе</link>,
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
20 указанной в содержащем location.
1946
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
21 Группа должна находиться в
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
22 <link doc="ngx_http_upstream_module.xml" id="zone">зоне разделяемой памяти</link>.
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
23 </para>
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
24
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
25 <para>
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
26 Если проверка работоспособности была неуспешной,
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
27 то сервер признаётся неработоспособным.
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
28 Если для группы задано несколько проверок,
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
29 то при любой неуспешной проверке соответствующий сервер будет
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
30 считаться неработоспособным.
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
31 На неработоспособные серверы и серверы в состоянии “checking”
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
32 клиентские запросы передаваться не будут.
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
33 </para>
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
34
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
35 <para>
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
36 <note>
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
37 Обратите внимание, что при использовании проверок
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
38 большинство переменных имеют пустые значения.
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
39 </note>
1945
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
40 </para>
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
41
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
42 <para>
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
43 <note>
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
44 Модуль доступен как часть
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
45 <commercial_version>коммерческой подписки</commercial_version>.
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
46 </note>
76
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
47 </para>
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
48
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
49 </section>
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
50
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
51
292
7bc830cc79bb Revision.
Ruslan Ermilov <ru@nginx.com>
parents: 280
diff changeset
52 <section id="example" name="Пример конфигурации">
76
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
53
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
54 <para>
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
55 <example>
1945
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
56 upstream dynamic {
1259
954dcc02cb63 Upstream: "session learn" sticky method and upstream_conf changes.
Ruslan Ermilov <ru@nginx.com>
parents: 1243
diff changeset
57 zone upstream_dynamic 64k;
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
58
1259
954dcc02cb63 Upstream: "session learn" sticky method and upstream_conf changes.
Ruslan Ermilov <ru@nginx.com>
parents: 1243
diff changeset
59 server backend1.example.com weight=5;
954dcc02cb63 Upstream: "session learn" sticky method and upstream_conf changes.
Ruslan Ermilov <ru@nginx.com>
parents: 1243
diff changeset
60 server backend2.example.com:8080 fail_timeout=5s slow_start=30s;
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
61 server 192.0.2.1 max_fails=3;
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
62
1259
954dcc02cb63 Upstream: "session learn" sticky method and upstream_conf changes.
Ruslan Ermilov <ru@nginx.com>
parents: 1243
diff changeset
63 server backup1.example.com:8080 backup;
954dcc02cb63 Upstream: "session learn" sticky method and upstream_conf changes.
Ruslan Ermilov <ru@nginx.com>
parents: 1243
diff changeset
64 server backup2.example.com:8080 backup;
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
65 }
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
66
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
67 server {
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
68 location / {
1945
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
69 proxy_pass http://dynamic;
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
70 health_check;
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
71 }
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
72 }
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
73 </example>
1946
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
74 Каждому серверу группы <literal>backend</literal>
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
75 с интервалом в 5 секунд посылаются запросы “<literal>/</literal>”.
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
76 Если происходит ошибка или таймаут при работе с сервером, или
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
77 код ответа проксируемого сервера не равен
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
78 2xx или 3xx, проверка считается неуспешной и сервер
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
79 признаётся неработоспособным.
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
80 </para>
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
81
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
82 <para>
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
83 Проверки работоспособности могут тестировать код ответа,
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
84 наличие или отсутствие определённых полей заголовка и их значений,
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
85 а также содержимое тела ответа.
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
86 Тесты настраиваются отдельно при помощи директивы <link id="match"/>
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
87 и указываются в параметре <literal>match</literal>.
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
88 Например:
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
89 <example>
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
90 http {
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
91 server {
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
92 ...
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
93 location / {
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
94 proxy_pass http://backend;
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
95 health_check match=welcome;
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
96 }
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
97 }
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
98
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
99 match welcome {
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
100 status 200;
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
101 header Content-Type = text/html;
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
102 body ~ "Welcome to nginx!";
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
103 }
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
104 }
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
105 </example>
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
106 В такой конфигурации успешный ответ на проверочный запрос
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
107 должен иметь код 200, тип содержимого “<literal>text/html</literal>”
37df1535ea91 Moved info from http "health_check" and "match" to intro.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1945
diff changeset
108 и “<literal>Welcome to nginx!</literal>” в теле ответа.
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
109 </para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
110
76
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
111 </section>
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
112
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
113
292
7bc830cc79bb Revision.
Ruslan Ermilov <ru@nginx.com>
parents: 280
diff changeset
114 <section id="directives" name="Директивы">
76
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
115
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
116 <directive name="health_check">
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
117 <syntax>[<value>параметры</value>]</syntax>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
118 <default/>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
119 <context>location</context>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
120
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
121 <para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
122 Активирует периодические проверки работоспособности серверов в
1945
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
123 <link doc="ngx_http_upstream_module.xml" id="upstream">группе</link>,
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
124 указанной в содержащем location.
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
125 </para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
126
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
127 <para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
128 Могут быть заданы следующие необязательные параметры:
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
129 <list type="tag">
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
130
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
131 <tag-name id="interval">
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
132 <literal>interval</literal>=<value>время</value>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
133 </tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
134 <tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
135 задаёт интервал между двумя последовательными проверками,
1891
6225d50b3cba Replaced semicolon with dot in health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1866
diff changeset
136 по умолчанию 5 секунд.
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
137 </tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
138
1866
6f2c5a36b4d1 Documented the "jitter" parameter for health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1854
diff changeset
139 <tag-name id="health_check_jitter">
6f2c5a36b4d1 Documented the "jitter" parameter for health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1854
diff changeset
140 <literal>jitter</literal>=<value>время</value>
6f2c5a36b4d1 Documented the "jitter" parameter for health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1854
diff changeset
141 </tag-name>
6f2c5a36b4d1 Documented the "jitter" parameter for health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1854
diff changeset
142 <tag-desc>
6f2c5a36b4d1 Documented the "jitter" parameter for health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1854
diff changeset
143 задаёт время, в пределах которого
6f2c5a36b4d1 Documented the "jitter" parameter for health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1854
diff changeset
144 случайным образом задерживается каждая проверка,
1891
6225d50b3cba Replaced semicolon with dot in health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1866
diff changeset
145 по умолчанию задержки нет.
1866
6f2c5a36b4d1 Documented the "jitter" parameter for health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1854
diff changeset
146 </tag-desc>
6f2c5a36b4d1 Documented the "jitter" parameter for health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1854
diff changeset
147
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
148 <tag-name id="fails">
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
149 <literal>fails</literal>=<value>число</value>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
150 </tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
151 <tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
152 задаёт число последовательных неуспешных проверок для определённого сервера,
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
153 после которых сервер будет считаться неработоспособным,
1891
6225d50b3cba Replaced semicolon with dot in health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1866
diff changeset
154 по умолчанию 1.
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
155 </tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
156
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
157 <tag-name id="passes">
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
158 <literal>passes</literal>=<value>число</value>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
159 </tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
160 <tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
161 задаёт число последовательных успешных проверок для определённого сервера,
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
162 после которых сервер будет считаться работоспособным,
1891
6225d50b3cba Replaced semicolon with dot in health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1866
diff changeset
163 по умолчанию 1.
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
164 </tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
165
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
166 <tag-name id="uri">
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
167 <literal>uri</literal>=<value>uri</value>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
168 </tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
169 <tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
170 задаёт URI, используемый в запросах, проверяющих работоспособность,
1891
6225d50b3cba Replaced semicolon with dot in health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1866
diff changeset
171 по умолчанию “<literal>/</literal>”.
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
172 </tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
173
1925
a58b35cc0823 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1891
diff changeset
174 <tag-name id="health_check_mandatory">
a58b35cc0823 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1891
diff changeset
175 <literal>mandatory</literal>
a58b35cc0823 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1891
diff changeset
176 </tag-name>
a58b35cc0823 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1891
diff changeset
177 <tag-desc>
a58b35cc0823 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1891
diff changeset
178 устанавливает исходное состояние “checking” для сервера
a58b35cc0823 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1891
diff changeset
179 до завершения первой проверки работоспособности (1.11.7).
a58b35cc0823 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1891
diff changeset
180 Если параметр не указан,
a58b35cc0823 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1891
diff changeset
181 то исходно сервер будет считаться работоспособным.
a58b35cc0823 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1891
diff changeset
182 </tag-desc>
a58b35cc0823 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1891
diff changeset
183
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
184 <tag-name id="hc_match">
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
185 <literal>match</literal>=<value>имя</value>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
186 </tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
187 <tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
188 указывает на блок <literal>match</literal> с условиями, которым должен
1891
6225d50b3cba Replaced semicolon with dot in health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1866
diff changeset
189 удовлетворять ответ, чтобы результат проверки считался успешным.
6225d50b3cba Replaced semicolon with dot in health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1866
diff changeset
190 По умолчанию код ответа должен быть 2xx или 3xx.
1636
44c4323144c5 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1625
diff changeset
191 </tag-desc>
44c4323144c5 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1625
diff changeset
192
44c4323144c5 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1625
diff changeset
193 <tag-name id="health_check_port">
44c4323144c5 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1625
diff changeset
194 <literal>port</literal>=<value>число</value>
44c4323144c5 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1625
diff changeset
195 </tag-name>
44c4323144c5 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1625
diff changeset
196 <tag-desc>
44c4323144c5 Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents: 1625
diff changeset
197 задаёт порт, используемый при подключении к серверу
1891
6225d50b3cba Replaced semicolon with dot in health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1866
diff changeset
198 для проверки его работоспособности (1.9.7).
1945
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
199 По умолчанию совпадает с портом
88477c5d2751 Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1925
diff changeset
200 <link doc="ngx_http_upstream_module.xml" id="server">сервера</link>.
1242
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
201 </tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
202
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
203 </list>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
204 </para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
205
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
206 </directive>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
207
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
208
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
209 <directive name="match">
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
210 <syntax block="yes"><value>имя</value></syntax>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
211 <default/>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
212 <context>http</context>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
213
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
214 <para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
215 Задаёт именованный набор тестов для анализа ответов
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
216 на запросы проверки работоспособности.
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
217 </para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
218
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
219 <para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
220 В ответе могут быть протестированы следующие объекты:
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
221 <list type="tag">
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
222
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
223 <tag-name><literal>status 200;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
224 <tag-desc>код ответа равен 200</tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
225
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
226 <tag-name><literal>status ! 500;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
227 <tag-desc>код ответа не равен 500</tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
228
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
229 <tag-name><literal>status 200 204;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
230 <tag-desc>код ответа равен 200 или 204</tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
231
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
232 <tag-name><literal>status ! 301 302;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
233 <tag-desc>код ответа не равен ни 301, ни 302</tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
234
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
235 <tag-name><literal>status 200-399;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
236 <tag-desc>код ответа находится в диапазоне от 200 до 399</tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
237
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
238 <tag-name><literal>status ! 400-599;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
239 <tag-desc>код ответа находится вне диапазона от 400 до 599</tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
240
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
241 <tag-name><literal>status 301-303 307;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
242 <tag-desc>код ответа равен 301, 302, 303 или 307</tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
243
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
244 </list>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
245
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
246 <list type="tag">
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
247
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
248 <tag-name><literal>header Content-Type = text/html;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
249 <tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
250 заголовок содержит <header>Content-Type</header>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
251 со значением <literal>text/html</literal>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
252 </tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
253
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
254 <tag-name><literal>header Content-Type != text/html;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
255 <tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
256 заголовок содержит <header>Content-Type</header>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
257 со значением, отличным от <literal>text/html</literal>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
258 </tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
259
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
260 <tag-name><literal>header Connection ~ close;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
261 <tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
262 заголовок содержит <header>Connection</header>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
263 со значением, совпадающим с регулярным выражением <literal>close</literal>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
264 </tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
265
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
266 <tag-name><literal>header Connection !~ close;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
267 <tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
268 заголовок содержит <header>Connection</header>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
269 со значением, не совпадающим с регулярным выражением <literal>close</literal>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
270 </tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
271
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
272 <tag-name><literal>header Host;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
273 <tag-desc>заголовок содержит <header>Host</header></tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
274
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
275 <tag-name><literal>header ! X-Accel-Redirect;</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
276 <tag-desc>заголовок не содержит <header>X-Accel-Redirect</header></tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
277
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
278 </list>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
279
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
280 <list type="tag">
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
281
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
282 <tag-name><literal>body ~ "Welcome to nginx!";</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
283 <tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
284 тело ответа совпадает с регулярным выражением
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
285 “<literal>Welcome to nginx!</literal>”
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
286 </tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
287
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
288 <tag-name><literal>body !~ "Welcome to nginx!";</literal></tag-name>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
289 <tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
290 тело ответа не совпадает с регулярным выражением
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
291 “<literal>Welcome to nginx!</literal>”
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
292 </tag-desc>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
293
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
294 </list>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
295 </para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
296
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
297 <para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
298 Если задано несколько тестов,
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
299 то ответ должен удовлетворять всем тестам.
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
300 <note>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
301 Проверяются только первые 256 Кбайт тела ответа.
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
302 </note>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
303 </para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
304
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
305 <para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
306 Примеры:
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
307 <example>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
308 # код ответа 200, тип содержимого "text/html"
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
309 # и тело ответа содержит "Welcome to nginx!"
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
310 match welcome {
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
311 status 200;
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
312 header Content-Type = text/html;
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
313 body ~ "Welcome to nginx!";
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
314 }
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
315 </example>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
316
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
317 <example>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
318 # код ответа не равен 301, 302, 303 и 307 и заголовок не содержит "Refresh:"
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
319 match not_redirect {
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
320 status ! 301-303 307;
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
321 header ! Refresh;
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
322 }
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
323 </example>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
324
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
325 <example>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
326 # код ответа успешный и сервер не в сервисном режиме
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
327 match server_ok {
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
328 status 200-399;
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
329 body !~ "maintenance mode";
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
330 }
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
331 </example>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
332
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
333 </para>
935fe5eb82c4 Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1241
diff changeset
334
1237
e0a1a929a458 Upstream: translated the sticky_cookie_insert directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1234
diff changeset
335 </directive>
e0a1a929a458 Upstream: translated the sticky_cookie_insert directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents: 1234
diff changeset
336
76
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
337 </section>
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
338
4a4caa566120 Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff changeset
339 </module>