Mercurial > hg > nginx-vendor-current
comparison src/event/ngx_event_connect.h @ 260:0effe91f6083 NGINX_0_5_0
nginx 0.5.0
*) Change: the parameters in the "%name" form in the "log_format"
directive are not supported anymore.
*) Change: the "proxy_upstream_max_fails",
"proxy_upstream_fail_timeout", "fastcgi_upstream_max_fails",
"fastcgi_upstream_fail_timeout", "memcached_upstream_max_fails", and
"memcached_upstream_fail_timeout" directives are not supported
anymore.
*) Feature: the "server" directive in the "upstream" context supports
the "max_fails", "fail_timeout", and "down" parameters.
*) Feature: the "ip_hash" directive inside the "upstream" block.
*) Feature: the WAIT status in the "Auth-Status" header line of the
IMAP/POP3 proxy authentication server response.
*) Bugfix: nginx could not be built on 64-bit platforms; bug appeared
in 0.4.14.
author | Igor Sysoev <http://sysoev.ru> |
---|---|
date | Mon, 04 Dec 2006 00:00:00 +0300 |
parents | d2ae1c9f1fd3 |
children | fc223117327f |
comparison
equal
deleted
inserted
replaced
259:c68f18041059 | 260:0effe91f6083 |
---|---|
11 #include <ngx_config.h> | 11 #include <ngx_config.h> |
12 #include <ngx_core.h> | 12 #include <ngx_core.h> |
13 #include <ngx_event.h> | 13 #include <ngx_event.h> |
14 | 14 |
15 | 15 |
16 typedef struct { | 16 #define NGX_PEER_KEEPALIVE 1 |
17 ngx_peers_t *peers; | 17 #define NGX_PEER_NEXT 2 |
18 ngx_uint_t cur_peer; | 18 #define NGX_PEER_FAILED 4 |
19 ngx_uint_t tries; | |
20 | 19 |
21 ngx_connection_t *connection; | 20 |
22 #if (NGX_THREADS) | 21 typedef struct ngx_peer_connection_s ngx_peer_connection_t; |
23 ngx_atomic_t *lock; | 22 |
23 typedef ngx_int_t (*ngx_event_get_peer_pt)(ngx_peer_connection_t *pc, | |
24 void *data); | |
25 #if (NGX_SSL) | |
26 typedef void (*ngx_event_save_peer_pt)(ngx_peer_connection_t *pc, void *data); | |
27 #endif | |
28 typedef void (*ngx_event_free_peer_pt)(ngx_peer_connection_t *pc, void *data, | |
29 ngx_uint_t state); | |
30 | |
31 | |
32 struct ngx_peer_connection_s { | |
33 ngx_connection_t *connection; | |
34 | |
35 struct sockaddr *sockaddr; | |
36 socklen_t socklen; | |
37 ngx_str_t *name; | |
38 | |
39 ngx_uint_t tries; | |
40 | |
41 ngx_event_get_peer_pt get; | |
42 ngx_event_free_peer_pt free; | |
43 void *data; | |
44 | |
45 #if (NGX_SSL) | |
46 ngx_ssl_session_t *ssl_session; | |
47 ngx_event_save_peer_pt save_session; | |
24 #endif | 48 #endif |
25 | 49 |
26 int rcvbuf; | 50 #if (NGX_THREADS) |
51 ngx_atomic_t *lock; | |
52 #endif | |
27 | 53 |
28 ngx_log_t *log; | 54 int rcvbuf; |
29 | 55 |
30 unsigned cached:1; | 56 ngx_log_t *log; |
31 unsigned log_error:2; /* ngx_connection_log_error_e */ | 57 |
32 } ngx_peer_connection_t; | 58 unsigned cached:1; |
59 unsigned log_error:2; /* ngx_connection_log_error_e */ | |
60 }; | |
33 | 61 |
34 | 62 |
35 ngx_int_t ngx_event_connect_peer(ngx_peer_connection_t *pc); | 63 ngx_int_t ngx_event_connect_peer(ngx_peer_connection_t *pc); |
36 void ngx_event_connect_peer_failed(ngx_peer_connection_t *pc, ngx_uint_t down); | 64 ngx_int_t ngx_event_get_peer(ngx_peer_connection_t *pc, void *data); |
65 | |
37 | 66 |
38 | 67 |
39 #endif /* _NGX_EVENT_CONNECT_H_INCLUDED_ */ | 68 #endif /* _NGX_EVENT_CONNECT_H_INCLUDED_ */ |