comparison src/http/modules/ngx_http_proxy_module.c @ 378:820f6378fc00 NGINX_0_7_1

nginx 0.7.1 *) Change: now locations are searched in a tree. *) Change: the "optimize_server_names" directive was canceled due to the "server_name_in_redirect" directive introduction. *) Change: some long deprecated directives are not supported anymore. *) Change: the "none" parameter in the "ssl_session_cache" directive; now this is default parameter. Thanks to Rob Mueller. *) Bugfix: worker processes might not catch reconfiguration and log rotation signals. *) Bugfix: nginx could not be built on latest Fedora 9 Linux. Thanks to Roxis.
author Igor Sysoev <http://sysoev.ru>
date Mon, 26 May 2008 00:00:00 +0400
parents babd3d9efb62
children 984bb0b1399b
comparison
equal deleted inserted replaced
377:5d98007adb5f 378:820f6378fc00
140 140
141 141
142 static ngx_conf_post_t ngx_http_proxy_lowat_post = 142 static ngx_conf_post_t ngx_http_proxy_lowat_post =
143 { ngx_http_proxy_lowat_check }; 143 { ngx_http_proxy_lowat_check };
144 144
145 static ngx_conf_deprecated_t ngx_conf_deprecated_proxy_header_buffer_size = {
146 ngx_conf_deprecated, "proxy_header_buffer_size", "proxy_buffer_size"
147 };
148
149 static ngx_conf_deprecated_t ngx_conf_deprecated_proxy_redirect_errors = {
150 ngx_conf_deprecated, "proxy_redirect_errors", "proxy_intercept_errors"
151 };
152
153 145
154 static ngx_conf_bitmask_t ngx_http_proxy_next_upstream_masks[] = { 146 static ngx_conf_bitmask_t ngx_http_proxy_next_upstream_masks[] = {
155 { ngx_string("error"), NGX_HTTP_UPSTREAM_FT_ERROR }, 147 { ngx_string("error"), NGX_HTTP_UPSTREAM_FT_ERROR },
156 { ngx_string("timeout"), NGX_HTTP_UPSTREAM_FT_TIMEOUT }, 148 { ngx_string("timeout"), NGX_HTTP_UPSTREAM_FT_TIMEOUT },
157 { ngx_string("invalid_header"), NGX_HTTP_UPSTREAM_FT_INVALID_HEADER }, 149 { ngx_string("invalid_header"), NGX_HTTP_UPSTREAM_FT_INVALID_HEADER },
233 ngx_conf_set_flag_slot, 225 ngx_conf_set_flag_slot,
234 NGX_HTTP_LOC_CONF_OFFSET, 226 NGX_HTTP_LOC_CONF_OFFSET,
235 offsetof(ngx_http_proxy_loc_conf_t, upstream.intercept_errors), 227 offsetof(ngx_http_proxy_loc_conf_t, upstream.intercept_errors),
236 NULL }, 228 NULL },
237 229
238 { ngx_string("proxy_redirect_errors"),
239 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_FLAG,
240 ngx_conf_set_flag_slot,
241 NGX_HTTP_LOC_CONF_OFFSET,
242 offsetof(ngx_http_proxy_loc_conf_t, upstream.intercept_errors),
243 &ngx_conf_deprecated_proxy_redirect_errors },
244
245 { ngx_string("proxy_set_header"), 230 { ngx_string("proxy_set_header"),
246 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_TAKE2, 231 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_TAKE2,
247 ngx_conf_set_keyval_slot, 232 ngx_conf_set_keyval_slot,
248 NGX_HTTP_LOC_CONF_OFFSET, 233 NGX_HTTP_LOC_CONF_OFFSET,
249 offsetof(ngx_http_proxy_loc_conf_t, headers_source), 234 offsetof(ngx_http_proxy_loc_conf_t, headers_source),
295 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_TAKE1, 280 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_TAKE1,
296 ngx_conf_set_size_slot, 281 ngx_conf_set_size_slot,
297 NGX_HTTP_LOC_CONF_OFFSET, 282 NGX_HTTP_LOC_CONF_OFFSET,
298 offsetof(ngx_http_proxy_loc_conf_t, upstream.buffer_size), 283 offsetof(ngx_http_proxy_loc_conf_t, upstream.buffer_size),
299 NULL }, 284 NULL },
300
301 { ngx_string("proxy_header_buffer_size"),
302 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_TAKE1,
303 ngx_conf_set_size_slot,
304 NGX_HTTP_LOC_CONF_OFFSET,
305 offsetof(ngx_http_proxy_loc_conf_t, upstream.buffer_size),
306 &ngx_conf_deprecated_proxy_header_buffer_size },
307 285
308 { ngx_string("proxy_read_timeout"), 286 { ngx_string("proxy_read_timeout"),
309 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_TAKE1, 287 NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_TAKE1,
310 ngx_conf_set_msec_slot, 288 ngx_conf_set_msec_slot,
311 NGX_HTTP_LOC_CONF_OFFSET, 289 NGX_HTTP_LOC_CONF_OFFSET,
1222 ngx_http_upstream_header_t *hh; 1200 ngx_http_upstream_header_t *hh;
1223 ngx_http_upstream_main_conf_t *umcf; 1201 ngx_http_upstream_main_conf_t *umcf;
1224 1202
1225 umcf = ngx_http_get_module_main_conf(r, ngx_http_upstream_module); 1203 umcf = ngx_http_get_module_main_conf(r, ngx_http_upstream_module);
1226 1204
1227 for ( ;; ) { 1205 for ( ;; ) {
1228 1206
1229 rc = ngx_http_parse_header_line(r, &r->upstream->buffer); 1207 rc = ngx_http_parse_header_line(r, &r->upstream->buffer);
1230 1208
1231 if (rc == NGX_OK) { 1209 if (rc == NGX_OK) {
1232 1210