Mercurial > hg > nginx-site
annotate xml/ru/docs/http/ngx_http_upstream_hc_module.xml @ 2841:55a573521ac3
Linux packages: added Ubuntu 22.04 "jammy".
author | Konstantin Pavlov <thresh@nginx.com> |
---|---|
date | Fri, 29 Apr 2022 21:36:07 +0400 |
parents | efb3d27dfa23 |
children | 8bd6f772005f |
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 | 11 lang="ru" |
2359
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
12 rev="5"> |
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 | 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 | 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 |
1949
8f9c685dfabd
Updated IDs in "health_check" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1946
diff
changeset
|
131 <tag-name id="health_check_interval"> |
1242
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 |
1949
8f9c685dfabd
Updated IDs in "health_check" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1946
diff
changeset
|
148 <tag-name id="health_check_fails"> |
1242
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 |
1949
8f9c685dfabd
Updated IDs in "health_check" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1946
diff
changeset
|
157 <tag-name id="health_check_passes"> |
1242
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 |
1949
8f9c685dfabd
Updated IDs in "health_check" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1946
diff
changeset
|
166 <tag-name id="health_check_uri"> |
1242
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"> |
2713
efb3d27dfa23
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2632
diff
changeset
|
175 <literal>mandatory</literal> [<literal>persistent</literal>] |
1925
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> |
2713
efb3d27dfa23
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2632
diff
changeset
|
178 <para> |
1925
a58b35cc0823
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1891
diff
changeset
|
179 устанавливает исходное состояние “checking” для сервера |
a58b35cc0823
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1891
diff
changeset
|
180 до завершения первой проверки работоспособности (1.11.7). |
1950
ef22a80a2696
Described the "checking" state in "health_check mandatory"
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1949
diff
changeset
|
181 На серверы в состоянии “checking” клиентские запросы передаваться не будут. |
1925
a58b35cc0823
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1891
diff
changeset
|
182 Если параметр не указан, |
a58b35cc0823
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1891
diff
changeset
|
183 то исходно сервер будет считаться работоспособным. |
2713
efb3d27dfa23
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2632
diff
changeset
|
184 </para> |
efb3d27dfa23
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2632
diff
changeset
|
185 |
efb3d27dfa23
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2632
diff
changeset
|
186 <para id="health_check_persistent"> |
efb3d27dfa23
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2632
diff
changeset
|
187 Параметр <literal>persistent</literal> (1.19.7) |
efb3d27dfa23
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2632
diff
changeset
|
188 устанавливает исходное состояние “up” для сервера после перезагрузки nginx |
efb3d27dfa23
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2632
diff
changeset
|
189 в случае, если до перезагрузки сервер считался работоспособным. |
efb3d27dfa23
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2632
diff
changeset
|
190 </para> |
1925
a58b35cc0823
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1891
diff
changeset
|
191 </tag-desc> |
a58b35cc0823
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1891
diff
changeset
|
192 |
1949
8f9c685dfabd
Updated IDs in "health_check" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1946
diff
changeset
|
193 <tag-name id="health_check_match"> |
1242
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
194 <literal>match</literal>=<value>имя</value> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
195 </tag-name> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
196 <tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
197 указывает на блок <literal>match</literal> с условиями, которым должен |
1891
6225d50b3cba
Replaced semicolon with dot in health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1866
diff
changeset
|
198 удовлетворять ответ, чтобы результат проверки считался успешным. |
6225d50b3cba
Replaced semicolon with dot in health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1866
diff
changeset
|
199 По умолчанию код ответа должен быть 2xx или 3xx. |
1636
44c4323144c5
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1625
diff
changeset
|
200 </tag-desc> |
44c4323144c5
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1625
diff
changeset
|
201 |
44c4323144c5
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1625
diff
changeset
|
202 <tag-name id="health_check_port"> |
44c4323144c5
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1625
diff
changeset
|
203 <literal>port</literal>=<value>число</value> |
44c4323144c5
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1625
diff
changeset
|
204 </tag-name> |
44c4323144c5
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1625
diff
changeset
|
205 <tag-desc> |
44c4323144c5
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1625
diff
changeset
|
206 задаёт порт, используемый при подключении к серверу |
1891
6225d50b3cba
Replaced semicolon with dot in health_check.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1866
diff
changeset
|
207 для проверки его работоспособности (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
|
208 По умолчанию совпадает с портом |
88477c5d2751
Moved "health_check" and "match" to ngx_http_upstream_hc_module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1925
diff
changeset
|
209 <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
|
210 </tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
211 |
2632
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
212 <tag-name id="health_check_grpc"> |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
213 <literal>type</literal>=<literal>grpc</literal> |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
214 [<literal>grpc_service</literal>=<value>имя</value>] |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
215 [<literal>grpc_status</literal>=<value>код</value>] |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
216 </tag-name> |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
217 <tag-desc> |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
218 активирует периодические |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
219 <link url="https://github.com/grpc/grpc/blob/master/doc/health-checking.md#grpc-health-checking-protocol">проверки |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
220 работоспособности</link> gRPC-сервера |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
221 или службы gRPC, указанной при помощи необязательного |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
222 параметра <literal>grpc_service</literal> (1.19.5). |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
223 Если сервер не поддерживает протокол проверки работоспособности gRPC, |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
224 то можно использовать необязательный параметр <literal>grpc_status</literal> |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
225 для указания |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
226 <link url="https://github.com/grpc/grpc/blob/master/doc/statuscodes.md#status-codes-and-their-use-in-grpc">статуса</link> |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
227 (например |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
228 статус “<literal>12</literal>” / “<literal>UNIMPLEMENTED</literal>”) |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
229 при получении которого сервер признаётся работоспособным: |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
230 <example> |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
231 health_check mandatory type=grpc grpc_status=12; |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
232 </example> |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
233 Параметр <literal>type</literal>=<literal>grpc</literal> |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
234 должен быть указан после остальных параметров директивы, |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
235 <literal>grpc_service</literal> и <literal>grpc_status</literal> |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
236 должны быть указаны после <literal>type</literal>=<literal>grpc</literal>. |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
237 Параметр несовместим с параметрами |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
238 <link id="health_check_uri"><literal>uri</literal></link> и |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
239 <link id="health_check_match"><literal>match</literal></link>. |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
240 </tag-desc> |
52500ccb82c1
Updated docs for the upcoming NGINX Plus release.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
2359
diff
changeset
|
241 |
1242
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
242 </list> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
243 </para> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
244 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
245 </directive> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
246 |
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 <directive name="match"> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
249 <syntax block="yes"><value>имя</value></syntax> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
250 <default/> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
251 <context>http</context> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
252 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
253 <para> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
254 Задаёт именованный набор тестов для анализа ответов |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
255 на запросы проверки работоспособности. |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
256 </para> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
257 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
258 <para> |
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 <list type="tag"> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
261 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
262 <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
|
263 <tag-desc>код ответа равен 200</tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
264 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
265 <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
|
266 <tag-desc>код ответа не равен 500</tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
267 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
268 <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
|
269 <tag-desc>код ответа равен 200 или 204</tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
270 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
271 <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
|
272 <tag-desc>код ответа не равен ни 301, ни 302</tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
273 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
274 <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
|
275 <tag-desc>код ответа находится в диапазоне от 200 до 399</tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
276 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
277 <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
|
278 <tag-desc>код ответа находится вне диапазона от 400 до 599</tag-desc> |
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 <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
|
281 <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
|
282 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
283 </list> |
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 <list type="tag"> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
286 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
287 <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
|
288 <tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
289 заголовок содержит <header>Content-Type</header> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
290 со значением <literal>text/html</literal> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
291 </tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
292 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
293 <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
|
294 <tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
295 заголовок содержит <header>Content-Type</header> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
296 со значением, отличным от <literal>text/html</literal> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
297 </tag-desc> |
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 <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
|
300 <tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
301 заголовок содержит <header>Connection</header> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
302 со значением, совпадающим с регулярным выражением <literal>close</literal> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
303 </tag-desc> |
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 <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
|
306 <tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
307 заголовок содержит <header>Connection</header> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
308 со значением, не совпадающим с регулярным выражением <literal>close</literal> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
309 </tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
310 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
311 <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
|
312 <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
|
313 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
314 <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
|
315 <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
|
316 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
317 </list> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
318 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
319 <list type="tag"> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
320 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
321 <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
|
322 <tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
323 тело ответа совпадает с регулярным выражением |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
324 “<literal>Welcome to nginx!</literal>” |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
325 </tag-desc> |
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 <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
|
328 <tag-desc> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
329 тело ответа не совпадает с регулярным выражением |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
330 “<literal>Welcome to nginx!</literal>” |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
331 </tag-desc> |
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 </list> |
2359
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
334 |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
335 <list type="tag"> |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
336 |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
337 <tag-name id="match_require"><literal>require</literal> |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
338 <value>$переменная</value> |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
339 <literal>...;</literal></tag-name> |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
340 <tag-desc> |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
341 все указанные переменные непустые и не равны “0” (1.15.9). |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
342 </tag-desc> |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
343 |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
344 </list> |
1242
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
345 </para> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
346 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
347 <para> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
348 Если задано несколько тестов, |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
349 то ответ должен удовлетворять всем тестам. |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
350 <note> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
351 Проверяются только первые 256 Кбайт тела ответа. |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
352 </note> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
353 </para> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
354 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
355 <para> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
356 Примеры: |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
357 <example> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
358 # код ответа 200, тип содержимого "text/html" |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
359 # и тело ответа содержит "Welcome to nginx!" |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
360 match welcome { |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
361 status 200; |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
362 header Content-Type = text/html; |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
363 body ~ "Welcome to nginx!"; |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
364 } |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
365 </example> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
366 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
367 <example> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
368 # код ответа не равен 301, 302, 303 и 307 и заголовок не содержит "Refresh:" |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
369 match not_redirect { |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
370 status ! 301-303 307; |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
371 header ! Refresh; |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
372 } |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
373 </example> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
374 |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
375 <example> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
376 # код ответа успешный и сервер не в сервисном режиме |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
377 match server_ok { |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
378 status 200-399; |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
379 body !~ "maintenance mode"; |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
380 } |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
381 </example> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
382 |
2359
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
383 <example> |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
384 # код ответа равен 200 или 204 |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
385 map $upstream_status $good_status { |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
386 200 1; |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
387 204 1; |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
388 } |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
389 |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
390 match server_ok { |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
391 require $good_status; |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
392 } |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
393 </example> |
d5e576eb7677
Updated docs for the upcoming NGINX Plus release.
Ruslan Ermilov <ru@nginx.com>
parents:
1950
diff
changeset
|
394 |
1242
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
395 </para> |
935fe5eb82c4
Upstream: translated the "health_check" and "match" directives.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1241
diff
changeset
|
396 |
1237
e0a1a929a458
Upstream: translated the sticky_cookie_insert directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1234
diff
changeset
|
397 </directive> |
e0a1a929a458
Upstream: translated the sticky_cookie_insert directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1234
diff
changeset
|
398 |
76
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
399 </section> |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
400 |
4a4caa566120
Russian documentation import.
Maxim Dounin <mdounin@mdounin.ru>
parents:
diff
changeset
|
401 </module> |