comparison xml/en/docs/stream/ngx_stream_proxy_module.xml @ 1405:4569719f4247

Split stream module into stream_core and stream_proxy modules.
author Yaroslav Zhuravlev <yar@nginx.com>
date Thu, 05 Feb 2015 15:24:03 +0300
parents xml/en/docs/stream/ngx_stream_module.xml@66f227952864
children 50c72ad994b3
comparison
equal deleted inserted replaced
1404:54d39c91a14d 1405:4569719f4247
1 <?xml version="1.0"?>
2
3 <!--
4 Copyright (C) Nginx, Inc.
5 -->
6
7 <!DOCTYPE module SYSTEM "../../../../dtd/module.dtd">
8
9 <module name="Module ngx_stream_proxy_module"
10 link="/en/docs/stream/ngx_stream_proxy_module.html"
11 lang="en"
12 rev="1">
13
14 <section id="summary">
15
16 <para>
17 The <literal>ngx_stream_proxy_module</literal> module (1.7.7) allows passing
18 connections to another server over TCP and UNIX-domain sockets.
19 </para>
20
21 <para>
22 <note>
23 This module is available as part of our
24 <commercial_version>commercial subscription</commercial_version>.
25 </note>
26 </para>
27
28 </section>
29
30
31 <section id="example" name="Example Configuration">
32
33 <para>
34 <example>
35 server {
36 listen 127.0.0.1:12345;
37 proxy_pass 127.0.0.1:8080;
38 }
39
40 server {
41 listen 12345;
42 proxy_connect_timeout 1s;
43 proxy_timeout 3s;
44 proxy_pass example.com:12345;
45 }
46
47 server {
48 listen [::1]:12345;
49 proxy_pass unix:/tmp/stream.socket;
50 }
51 </example>
52 </para>
53
54 </section>
55
56
57 <section id="directives" name="Directives">
58
59 <directive name="proxy_connect_timeout">
60 <syntax><value>time</value></syntax>
61 <default>60s</default>
62 <context>stream</context>
63 <context>server</context>
64
65 <para>
66 Defines a timeout for establishing a connection with a proxied server.
67 </para>
68
69 </directive>
70
71
72 <directive name="proxy_downstream_buffer">
73 <syntax><value>size</value></syntax>
74 <default>16k</default>
75 <context>stream</context>
76 <context>server</context>
77
78 <para>
79 Sets the <value>size</value> of the
80 buffers used for reading data from the client.
81 </para>
82
83 </directive>
84
85
86 <directive name="proxy_pass">
87 <syntax><value>address</value></syntax>
88 <default/>
89 <context>server</context>
90
91 <para>
92 Sets the address of a proxied server.
93 The address can be specified as a domain name or IP address,
94 and an obligatory port:
95 <example>
96 proxy_pass localhost:12345;
97 </example>
98 or as a UNIX-domain socket path:
99 <example>
100 proxy_pass unix:/tmp/stream.socket;
101 </example>
102 </para>
103
104 <para>
105 If a domain name resolves to several addresses, all of them will be
106 used in a round-robin fashion.
107 In addition, an address can be specified as a
108 <link doc="ngx_stream_upstream_module.xml">server group</link>.
109 </para>
110
111 </directive>
112
113
114 <directive name="proxy_timeout">
115 <syntax><value>timeout</value></syntax>
116 <default>10m</default>
117 <context>stream</context>
118 <context>server</context>
119
120 <para>
121 Defines a timeout used after the proxying to the backend had started.
122 </para>
123
124 </directive>
125
126
127 <directive name="proxy_upstream_buffer">
128 <syntax><value>size</value></syntax>
129 <default>16k</default>
130 <context>stream</context>
131 <context>server</context>
132
133 <para>
134 Sets the <value>size</value> of the
135 buffers used for reading data from the upstream server.
136 </para>
137
138 </directive>
139
140 </section>
141
142 </module>