Mercurial > hg > nginx-site
annotate xml/en/docs/http/ngx_http_memcached_module.xml @ 838:d1b5814e5265
Controlling nginx: use "ps -w" in examples.
author | Ruslan Ermilov <ru@nginx.com> |
---|---|
date | Mon, 11 Feb 2013 12:26:17 +0400 |
parents | ed29fd8be462 |
children | 3a374868c798 |
rev | line source |
---|---|
363
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
1 <?xml version="1.0"?> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
2 |
580
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
364
diff
changeset
|
3 <!-- |
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
364
diff
changeset
|
4 Copyright (C) Igor Sysoev |
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
364
diff
changeset
|
5 Copyright (C) Nginx, Inc. |
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
364
diff
changeset
|
6 --> |
be54c443235a
Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents:
364
diff
changeset
|
7 |
363
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
8 <!DOCTYPE module SYSTEM "../../../../dtd/module.dtd"> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
9 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
10 <module name="Module ngx_http_memcached_module" |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
11 link="/en/docs/http/ngx_http_memcached_module.html" |
589 | 12 lang="en" |
815
ed29fd8be462
*_bind: variables support and inheritance.
Ruslan Ermilov <ru@nginx.com>
parents:
814
diff
changeset
|
13 rev="5"> |
363
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
14 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
15 <section id="summary"> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
16 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
17 <para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
18 The <literal>ngx_http_memcached_module</literal> module allows to obtain |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
19 responses from a memcached server. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
20 The key is set in the <var>$memcached_key</var> variable. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
21 A response should be put in memcached in advance via means that are |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
22 external to nginx. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
23 </para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
24 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
25 </section> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
26 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
27 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
28 <section id="example" name="Example Configuration"> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
29 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
30 <para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
31 <example> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
32 server { |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
33 location / { |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
34 set $memcached_key "$uri?$args"; |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
35 memcached_pass host:11211; |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
36 error_page 404 502 504 = @fallback; |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
37 } |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
38 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
39 location @fallback { |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
40 proxy_pass http://backend; |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
41 } |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
42 } |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
43 </example> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
44 </para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
45 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
46 </section> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
47 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
48 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
49 <section id="directives" name="Directives"> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
50 |
772
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
51 <directive name="memcached_bind"> |
815
ed29fd8be462
*_bind: variables support and inheritance.
Ruslan Ermilov <ru@nginx.com>
parents:
814
diff
changeset
|
52 <syntax><value>address</value> | <literal>off</literal></syntax> |
772
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
53 <default/> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
54 <context>http</context> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
55 <context>server</context> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
56 <context>location</context> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
57 <appeared-in>0.8.22</appeared-in> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
58 |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
59 <para> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
60 Forces outgoing connections to a memcached server to originate |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
61 from the specified local IP <value>address</value>. |
815
ed29fd8be462
*_bind: variables support and inheritance.
Ruslan Ermilov <ru@nginx.com>
parents:
814
diff
changeset
|
62 Value of the parameter can contain variables (1.3.12). |
ed29fd8be462
*_bind: variables support and inheritance.
Ruslan Ermilov <ru@nginx.com>
parents:
814
diff
changeset
|
63 The special value <literal>off</literal> (1.3.12) cancels the effect |
ed29fd8be462
*_bind: variables support and inheritance.
Ruslan Ermilov <ru@nginx.com>
parents:
814
diff
changeset
|
64 of the <literal>memcached_bind</literal> directive |
ed29fd8be462
*_bind: variables support and inheritance.
Ruslan Ermilov <ru@nginx.com>
parents:
814
diff
changeset
|
65 inherited from the previous configuration level, allowing the |
ed29fd8be462
*_bind: variables support and inheritance.
Ruslan Ermilov <ru@nginx.com>
parents:
814
diff
changeset
|
66 system to auto-assign local address. |
772
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
67 </para> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
68 |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
69 </directive> |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
70 |
ce121bf644f5
Documented "bind" directive in memcached, fastcgi and proxy modules.
Vladimir Homutov <vl@nginx.com>
parents:
677
diff
changeset
|
71 |
363
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
72 <directive name="memcached_buffer_size"> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
73 <syntax><value>size</value></syntax> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
74 <default>4k|8k</default> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
75 <context>http</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
76 <context>server</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
77 <context>location</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
78 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
79 <para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
80 Sets <value>size</value> of the buffer used for reading a response |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
81 received from the memcached server. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
82 A response is passed to a client synchronously, immediately as it is received. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
83 </para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
84 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
85 </directive> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
86 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
87 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
88 <directive name="memcached_connect_timeout"> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
89 <syntax><value>time</value></syntax> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
90 <default>60s</default> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
91 <context>http</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
92 <context>server</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
93 <context>location</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
94 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
95 <para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
96 Defines a timeout for establishing a connection with the memcached server. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
97 It should be noted that this timeout cannot usually exceed 75 seconds. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
98 </para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
99 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
100 </directive> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
101 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
102 |
675
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
103 <directive name="memcached_gzip_flag"> |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
104 <syntax><value>flag</value></syntax> |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
105 <default></default> |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
106 <context>http</context> |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
107 <context>server</context> |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
108 <context>location</context> |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
109 <appeared-in>1.3.6</appeared-in> |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
110 |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
111 <para> |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
112 Enables the test for the <value>flag</value> presence in the memcached |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
113 server response and sets the request header field |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
114 “<literal>Content-Encoding</literal>” to “<literal>gzip</literal>” |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
115 if the flag is set. |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
116 </para> |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
117 |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
118 </directive> |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
119 |
08140f6b7964
Documented gunzip module and corresponding changes.
Vladimir Homutov <vl@nginx.com>
parents:
589
diff
changeset
|
120 |
363
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
121 <directive name="memcached_next_upstream"> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
122 <syntax> |
364 | 123 <literal>error</literal> | |
124 <literal>timeout</literal> | | |
125 <literal>invalid_response</literal> | | |
126 <literal>not_found</literal> | | |
127 <literal>off</literal> | |
128 ...</syntax> | |
363
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
129 <default>error timeout</default> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
130 <context>http</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
131 <context>server</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
132 <context>location</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
133 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
134 <para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
135 Specifies in which cases a request should be passed to the next server: |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
136 <list type="tag"> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
137 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
138 <tag-name><literal>error</literal></tag-name> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
139 <tag-desc>an error occurred while establishing a connection with the |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
140 server, passing it a request, or reading the response header;</tag-desc> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
141 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
142 <tag-name><literal>timeout</literal></tag-name> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
143 <tag-desc>a timeout has occurred while establishing a connection with the |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
144 server, passing it a request, or reading the response header;</tag-desc> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
145 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
146 <tag-name><literal>invalid_response</literal></tag-name> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
147 <tag-desc>a server returned empty or invalid response;</tag-desc> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
148 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
149 <tag-name><literal>not_found</literal></tag-name> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
150 <tag-desc>a response was not found on the server;</tag-desc> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
151 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
152 <tag-name><literal>off</literal></tag-name> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
153 <tag-desc>disables passing a request to the next server.</tag-desc> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
154 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
155 </list> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
156 </para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
157 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
158 <para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
159 It should be understood that passing a request to the next server is |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
160 only possible if a client was not sent anything yet. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
161 That is, if an error or a timeout occurs in the middle of |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
162 transferring a response, fixing this is impossible. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
163 </para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
164 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
165 </directive> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
166 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
167 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
168 <directive name="memcached_pass"> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
169 <syntax><value>address</value></syntax> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
170 <default/> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
171 <context>location</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
172 <context>if in location</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
173 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
174 <para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
175 Sets an address of the memcached server. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
176 An address can be specified as a domain name or an address, and a port, |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
177 for example, |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
178 <example> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
179 memcached_pass localhost:11211; |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
180 </example> |
814
f46a132af596
"memcached_pass" can be a UNIX-domain socket.
Ruslan Ermilov <ru@nginx.com>
parents:
772
diff
changeset
|
181 or as a UNIX-domain socket path: |
f46a132af596
"memcached_pass" can be a UNIX-domain socket.
Ruslan Ermilov <ru@nginx.com>
parents:
772
diff
changeset
|
182 <example> |
f46a132af596
"memcached_pass" can be a UNIX-domain socket.
Ruslan Ermilov <ru@nginx.com>
parents:
772
diff
changeset
|
183 memcached_pass unix:/tmp/memcached.socket; |
f46a132af596
"memcached_pass" can be a UNIX-domain socket.
Ruslan Ermilov <ru@nginx.com>
parents:
772
diff
changeset
|
184 </example> |
363
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
185 </para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
186 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
187 <para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
188 If a domain name resolves to several addresses, all of them will be |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
189 used in a round-robin fashion. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
190 In addition, an address can be specified as a |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
191 <link doc="ngx_http_upstream_module.xml">server group</link>. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
192 </para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
193 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
194 </directive> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
195 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
196 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
197 <directive name="memcached_read_timeout"> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
198 <syntax><value>time</value></syntax> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
199 <default>60s</default> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
200 <context>http</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
201 <context>server</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
202 <context>location</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
203 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
204 <para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
205 Defines a timeout for reading a response from the memcached server. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
206 A timeout is only set between two successive read operations, |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
207 not for the transmission of the whole response. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
208 If a memcached server does not transmit anything within this time, |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
209 a connection is closed. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
210 </para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
211 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
212 </directive> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
213 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
214 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
215 <directive name="memcached_send_timeout"> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
216 <syntax><value>time</value></syntax> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
217 <default>60s</default> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
218 <context>http</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
219 <context>server</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
220 <context>location</context> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
221 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
222 <para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
223 Sets a timeout for transmitting a request to the memcached server. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
224 A timeout is only set between two successive write operations, |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
225 not for the transmission of the whole request. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
226 If a memcached server does not receive anything within this time, |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
227 a connection is closed. |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
228 </para> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
229 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
230 </directive> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
231 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
232 </section> |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
233 |
c7fccbe03827
English translation of ngx_http_memcached_module.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
234 </module> |