annotate src/core/ngx_connection.h @ 4515:8bb695c05870 stable-1.0

Merge of r4498: Fix of rbtree lookup on hash collisions. Previous code incorrectly assumed that nodes with identical keys are linked together. This might not be true after tree rebalance. Patch by Lanshun Zhou.
author Maxim Dounin <mdounin@mdounin.ru>
date Mon, 05 Mar 2012 13:17:56 +0000
parents 4919fb357a5d
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
441
da8c5707af39 nginx-0.1.0-2004-09-28-12:34:51 import; set copyright and remove unused files
Igor Sysoev <igor@sysoev.ru>
parents: 432
diff changeset
1
da8c5707af39 nginx-0.1.0-2004-09-28-12:34:51 import; set copyright and remove unused files
Igor Sysoev <igor@sysoev.ru>
parents: 432
diff changeset
2 /*
444
42d11f017717 nginx-0.1.0-2004-09-29-20:00:49 import; remove years from copyright
Igor Sysoev <igor@sysoev.ru>
parents: 441
diff changeset
3 * Copyright (C) Igor Sysoev
4450
4919fb357a5d Merge of r4406, r4413: copyrights updated.
Maxim Dounin <mdounin@mdounin.ru>
parents: 3880
diff changeset
4 * Copyright (C) Nginx, Inc.
441
da8c5707af39 nginx-0.1.0-2004-09-28-12:34:51 import; set copyright and remove unused files
Igor Sysoev <igor@sysoev.ru>
parents: 432
diff changeset
5 */
da8c5707af39 nginx-0.1.0-2004-09-28-12:34:51 import; set copyright and remove unused files
Igor Sysoev <igor@sysoev.ru>
parents: 432
diff changeset
6
da8c5707af39 nginx-0.1.0-2004-09-28-12:34:51 import; set copyright and remove unused files
Igor Sysoev <igor@sysoev.ru>
parents: 432
diff changeset
7
0
4eff17414a43 nginx-0.0.1-2002-08-06-20:39:45 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff changeset
8 #ifndef _NGX_CONNECTION_H_INCLUDED_
4eff17414a43 nginx-0.0.1-2002-08-06-20:39:45 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff changeset
9 #define _NGX_CONNECTION_H_INCLUDED_
4eff17414a43 nginx-0.0.1-2002-08-06-20:39:45 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff changeset
10
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
11
100
7ebc8b7fb816 nginx-0.0.1-2003-06-03-19:42:58 import
Igor Sysoev <igor@sysoev.ru>
parents: 99
diff changeset
12 #include <ngx_config.h>
92
19cc647ecd91 nginx-0.0.1-2003-05-20-19:37:55 import
Igor Sysoev <igor@sysoev.ru>
parents: 91
diff changeset
13 #include <ngx_core.h>
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
14
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
15
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
16 typedef struct ngx_listening_s ngx_listening_t;
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
17
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
18 struct ngx_listening_s {
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
19 ngx_socket_t fd;
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
20
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
21 struct sockaddr *sockaddr;
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
22 socklen_t socklen; /* size of sockaddr */
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
23 size_t addr_text_max_len;
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
24 ngx_str_t addr_text;
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
25
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
26 int type;
563
9c2f3ed7a247 nginx-0.3.3-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 557
diff changeset
27
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
28 int backlog;
563
9c2f3ed7a247 nginx-0.3.3-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 557
diff changeset
29 int rcvbuf;
9c2f3ed7a247 nginx-0.3.3-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 557
diff changeset
30 int sndbuf;
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
31
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
32 /* handler of accepted connection */
547
818fbd4750b9 nginx-0.2.2-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 543
diff changeset
33 ngx_connection_handler_pt handler;
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
34
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
35 void *servers; /* array of ngx_http_in_addr_t, for example */
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
36
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
37 ngx_log_t log;
2785
d478379e51ac *) refactor error_log processing: listen socket log might inherit built-in
Igor Sysoev <igor@sysoev.ru>
parents: 2562
diff changeset
38 ngx_log_t *logp;
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
39
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
40 size_t pool_size;
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
41 /* should be here because of the AcceptEx() preread */
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
42 size_t post_accept_buffer_size;
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
43 /* should be here because of the deferred accept */
557
ecd9c160f25b nginx-0.3.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 547
diff changeset
44 ngx_msec_t post_accept_timeout;
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
45
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
46 ngx_listening_t *previous;
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
47 ngx_connection_t *connection;
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
48
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
49 unsigned open:1;
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
50 unsigned remain:1;
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
51 unsigned ignore:1;
109
a9bc21d63fe4 nginx-0.0.1-2003-07-02-18:41:17 import
Igor Sysoev <igor@sysoev.ru>
parents: 103
diff changeset
52
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
53 unsigned bound:1; /* already bound */
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
54 unsigned inherited:1; /* inherited from previous process */
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
55 unsigned nonblocking_accept:1;
563
9c2f3ed7a247 nginx-0.3.3-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 557
diff changeset
56 unsigned listen:1;
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
57 unsigned nonblocking:1;
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
58 unsigned shared:1; /* shared between threads or processes */
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
59 unsigned addr_ntop:1;
523
2019117e6b38 nginx-0.1.36-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 521
diff changeset
60
2562
c352c419be85 ipv6only
Igor Sysoev <igor@sysoev.ru>
parents: 2560
diff changeset
61 #if (NGX_HAVE_INET6 && defined IPV6_V6ONLY)
c352c419be85 ipv6only
Igor Sysoev <igor@sysoev.ru>
parents: 2560
diff changeset
62 unsigned ipv6only:2;
c352c419be85 ipv6only
Igor Sysoev <igor@sysoev.ru>
parents: 2560
diff changeset
63 #endif
c352c419be85 ipv6only
Igor Sysoev <igor@sysoev.ru>
parents: 2560
diff changeset
64
469
2ff194b74f1e nginx-0.1.9-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 461
diff changeset
65 #if (NGX_HAVE_DEFERRED_ACCEPT)
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
66 unsigned deferred_accept:1;
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
67 unsigned delete_deferred:1;
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
68 unsigned add_deferred:1;
523
2019117e6b38 nginx-0.1.36-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 521
diff changeset
69 #ifdef SO_ACCEPTFILTER
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
70 char *accept_filter;
523
2019117e6b38 nginx-0.1.36-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 521
diff changeset
71 #endif
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
72 #endif
3676
4430d110293e listen setfib=X
Igor Sysoev <igor@sysoev.ru>
parents: 3263
diff changeset
73 #if (NGX_HAVE_SETFIB)
4430d110293e listen setfib=X
Igor Sysoev <igor@sysoev.ru>
parents: 3263
diff changeset
74 int setfib;
4430d110293e listen setfib=X
Igor Sysoev <igor@sysoev.ru>
parents: 3263
diff changeset
75 #endif
419
47709bff4468 nginx-0.0.10-2004-09-09-19:40:48 import
Igor Sysoev <igor@sysoev.ru>
parents: 417
diff changeset
76
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
77 };
92
19cc647ecd91 nginx-0.0.1-2003-05-20-19:37:55 import
Igor Sysoev <igor@sysoev.ru>
parents: 91
diff changeset
78
0
4eff17414a43 nginx-0.0.1-2002-08-06-20:39:45 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff changeset
79
256
8e39cab6abd5 nginx-0.0.2-2004-02-10-19:23:38 import
Igor Sysoev <igor@sysoev.ru>
parents: 253
diff changeset
80 typedef enum {
2560
a7443674e429 ignore EINVAL from setsockopt() on Solaris
Igor Sysoev <igor@sysoev.ru>
parents: 2512
diff changeset
81 NGX_ERROR_ALERT = 0,
256
8e39cab6abd5 nginx-0.0.2-2004-02-10-19:23:38 import
Igor Sysoev <igor@sysoev.ru>
parents: 253
diff changeset
82 NGX_ERROR_ERR,
8e39cab6abd5 nginx-0.0.2-2004-02-10-19:23:38 import
Igor Sysoev <igor@sysoev.ru>
parents: 253
diff changeset
83 NGX_ERROR_INFO,
2560
a7443674e429 ignore EINVAL from setsockopt() on Solaris
Igor Sysoev <igor@sysoev.ru>
parents: 2512
diff changeset
84 NGX_ERROR_IGNORE_ECONNRESET,
a7443674e429 ignore EINVAL from setsockopt() on Solaris
Igor Sysoev <igor@sysoev.ru>
parents: 2512
diff changeset
85 NGX_ERROR_IGNORE_EINVAL
256
8e39cab6abd5 nginx-0.0.2-2004-02-10-19:23:38 import
Igor Sysoev <igor@sysoev.ru>
parents: 253
diff changeset
86 } ngx_connection_log_error_e;
8e39cab6abd5 nginx-0.0.2-2004-02-10-19:23:38 import
Igor Sysoev <igor@sysoev.ru>
parents: 253
diff changeset
87
8e39cab6abd5 nginx-0.0.2-2004-02-10-19:23:38 import
Igor Sysoev <igor@sysoev.ru>
parents: 253
diff changeset
88
344
e366ba5db8f8 nginx-0.0.3-2004-06-01-10:04:46 import
Igor Sysoev <igor@sysoev.ru>
parents: 343
diff changeset
89 typedef enum {
483
621229427cba nginx-0.1.16-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 479
diff changeset
90 NGX_TCP_NODELAY_UNSET = 0,
621229427cba nginx-0.1.16-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 479
diff changeset
91 NGX_TCP_NODELAY_SET,
621229427cba nginx-0.1.16-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 479
diff changeset
92 NGX_TCP_NODELAY_DISABLED
621229427cba nginx-0.1.16-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 479
diff changeset
93 } ngx_connection_tcp_nodelay_e;
621229427cba nginx-0.1.16-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 479
diff changeset
94
621229427cba nginx-0.1.16-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 479
diff changeset
95
621229427cba nginx-0.1.16-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 479
diff changeset
96 typedef enum {
344
e366ba5db8f8 nginx-0.0.3-2004-06-01-10:04:46 import
Igor Sysoev <igor@sysoev.ru>
parents: 343
diff changeset
97 NGX_TCP_NOPUSH_UNSET = 0,
483
621229427cba nginx-0.1.16-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 479
diff changeset
98 NGX_TCP_NOPUSH_SET,
621229427cba nginx-0.1.16-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 479
diff changeset
99 NGX_TCP_NOPUSH_DISABLED
344
e366ba5db8f8 nginx-0.0.3-2004-06-01-10:04:46 import
Igor Sysoev <igor@sysoev.ru>
parents: 343
diff changeset
100 } ngx_connection_tcp_nopush_e;
e366ba5db8f8 nginx-0.0.3-2004-06-01-10:04:46 import
Igor Sysoev <igor@sysoev.ru>
parents: 343
diff changeset
101
e366ba5db8f8 nginx-0.0.3-2004-06-01-10:04:46 import
Igor Sysoev <igor@sysoev.ru>
parents: 343
diff changeset
102
829
362d156f0278 high level HTTP buffered flags should be on per-subrequest basis,
Igor Sysoev <igor@sysoev.ru>
parents: 641
diff changeset
103 #define NGX_LOWLEVEL_BUFFERED 0x0f
362d156f0278 high level HTTP buffered flags should be on per-subrequest basis,
Igor Sysoev <igor@sysoev.ru>
parents: 641
diff changeset
104 #define NGX_SSL_BUFFERED 0x01
597
9262f520ce21 nginx-0.3.20-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 583
diff changeset
105
9262f520ce21 nginx-0.3.20-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 583
diff changeset
106
0
4eff17414a43 nginx-0.0.1-2002-08-06-20:39:45 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff changeset
107 struct ngx_connection_s {
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
108 void *data;
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
109 ngx_event_t *read;
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
110 ngx_event_t *write;
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
111
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
112 ngx_socket_t fd;
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
113
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
114 ngx_recv_pt recv;
539
371c1cee100d nginx-0.1.44-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 537
diff changeset
115 ngx_send_pt send;
577
4d9ea73a627a nginx-0.3.10-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 563
diff changeset
116 ngx_recv_chain_pt recv_chain;
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
117 ngx_send_chain_pt send_chain;
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
118
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
119 ngx_listening_t *listening;
0
4eff17414a43 nginx-0.0.1-2002-08-06-20:39:45 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff changeset
120
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
121 off_t sent;
8
708f8bb772ec nginx-0.0.1-2002-09-02-18:48:24 import
Igor Sysoev <igor@sysoev.ru>
parents: 7
diff changeset
122
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
123 ngx_log_t *log;
57
a499e0d1f16e nginx-0.0.1-2003-01-30-10:28:09 import
Igor Sysoev <igor@sysoev.ru>
parents: 44
diff changeset
124
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
125 ngx_pool_t *pool;
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
126
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
127 struct sockaddr *sockaddr;
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
128 socklen_t socklen;
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
129 ngx_str_t addr_text;
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
130
577
4d9ea73a627a nginx-0.3.10-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 563
diff changeset
131 #if (NGX_SSL)
547
818fbd4750b9 nginx-0.2.2-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 543
diff changeset
132 ngx_ssl_connection_t *ssl;
392
d1222d46b3f9 nginx-0.0.7-2004-07-15-00:07:58 import
Igor Sysoev <igor@sysoev.ru>
parents: 380
diff changeset
133 #endif
d1222d46b3f9 nginx-0.0.7-2004-07-15-00:07:58 import
Igor Sysoev <igor@sysoev.ru>
parents: 380
diff changeset
134
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
135 struct sockaddr *local_sockaddr;
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
136
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
137 ngx_buf_t *buffer;
8
708f8bb772ec nginx-0.0.1-2002-09-02-18:48:24 import
Igor Sysoev <igor@sysoev.ru>
parents: 7
diff changeset
138
3880
e3cb8e27e413 reuse keepalive connections if there are no free worker connections
Igor Sysoev <igor@sysoev.ru>
parents: 3676
diff changeset
139 ngx_queue_t queue;
e3cb8e27e413 reuse keepalive connections if there are no free worker connections
Igor Sysoev <igor@sysoev.ru>
parents: 3676
diff changeset
140
495
fc9909c369b2 nginx-0.1.22-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 493
diff changeset
141 ngx_atomic_uint_t number;
26
53cb81681040 nginx-0.0.1-2002-12-15-09:25:09 import
Igor Sysoev <igor@sysoev.ru>
parents: 24
diff changeset
142
2888
512d164a8348 keepalive_requests
Igor Sysoev <igor@sysoev.ru>
parents: 2854
diff changeset
143 ngx_uint_t requests;
512d164a8348 keepalive_requests
Igor Sysoev <igor@sysoev.ru>
parents: 2854
diff changeset
144
829
362d156f0278 high level HTTP buffered flags should be on per-subrequest basis,
Igor Sysoev <igor@sysoev.ru>
parents: 641
diff changeset
145 unsigned buffered:8;
597
9262f520ce21 nginx-0.3.20-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 583
diff changeset
146
2560
a7443674e429 ignore EINVAL from setsockopt() on Solaris
Igor Sysoev <igor@sysoev.ru>
parents: 2512
diff changeset
147 unsigned log_error:3; /* ngx_connection_log_error_e */
256
8e39cab6abd5 nginx-0.0.2-2004-02-10-19:23:38 import
Igor Sysoev <igor@sysoev.ru>
parents: 253
diff changeset
148
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
149 unsigned single_connection:1;
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
150 unsigned unexpected_eof:1;
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
151 unsigned timedout:1;
583
4e296b7d25bf nginx-0.3.13-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 577
diff changeset
152 unsigned error:1;
4e296b7d25bf nginx-0.3.13-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 577
diff changeset
153 unsigned destroyed:1;
452
23fb87bddda1 nginx-0.1.1-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 444
diff changeset
154
1135
03f1133f24e8 close keep-alive connections in the shuting down processes
Igor Sysoev <igor@sysoev.ru>
parents: 829
diff changeset
155 unsigned idle:1;
3880
e3cb8e27e413 reuse keepalive connections if there are no free worker connections
Igor Sysoev <igor@sysoev.ru>
parents: 3676
diff changeset
156 unsigned reusable:1;
1135
03f1133f24e8 close keep-alive connections in the shuting down processes
Igor Sysoev <igor@sysoev.ru>
parents: 829
diff changeset
157 unsigned close:1;
03f1133f24e8 close keep-alive connections in the shuting down processes
Igor Sysoev <igor@sysoev.ru>
parents: 829
diff changeset
158
452
23fb87bddda1 nginx-0.1.1-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 444
diff changeset
159 unsigned sendfile:1;
23fb87bddda1 nginx-0.1.1-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 444
diff changeset
160 unsigned sndlowat:1;
483
621229427cba nginx-0.1.16-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 479
diff changeset
161 unsigned tcp_nodelay:2; /* ngx_connection_tcp_nodelay_e */
621229427cba nginx-0.1.16-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 479
diff changeset
162 unsigned tcp_nopush:2; /* ngx_connection_tcp_nopush_e */
452
23fb87bddda1 nginx-0.1.1-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 444
diff changeset
163
469
2ff194b74f1e nginx-0.1.9-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 461
diff changeset
164 #if (NGX_HAVE_IOCP)
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
165 unsigned accept_context_updated:1;
103
6dfda4cf5200 nginx-0.0.1-2003-06-11-19:28:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 101
diff changeset
166 #endif
370
54f76b0b8dca nginx-0.0.7-2004-06-27-22:01:57 import
Igor Sysoev <igor@sysoev.ru>
parents: 356
diff changeset
167
3065
113cd532b328 aio sendfile
Igor Sysoev <igor@sysoev.ru>
parents: 2888
diff changeset
168 #if (NGX_HAVE_AIO_SENDFILE)
113cd532b328 aio sendfile
Igor Sysoev <igor@sysoev.ru>
parents: 2888
diff changeset
169 unsigned aio_sendfile:1;
113cd532b328 aio sendfile
Igor Sysoev <igor@sysoev.ru>
parents: 2888
diff changeset
170 ngx_buf_t *busy_sendfile;
113cd532b328 aio sendfile
Igor Sysoev <igor@sysoev.ru>
parents: 2888
diff changeset
171 #endif
113cd532b328 aio sendfile
Igor Sysoev <igor@sysoev.ru>
parents: 2888
diff changeset
172
370
54f76b0b8dca nginx-0.0.7-2004-06-27-22:01:57 import
Igor Sysoev <igor@sysoev.ru>
parents: 356
diff changeset
173 #if (NGX_THREADS)
396
6f3b20c1ac50 nginx-0.0.7-2004-07-18-23:11:20 import
Igor Sysoev <igor@sysoev.ru>
parents: 393
diff changeset
174 ngx_atomic_t lock;
370
54f76b0b8dca nginx-0.0.7-2004-06-27-22:01:57 import
Igor Sysoev <igor@sysoev.ru>
parents: 356
diff changeset
175 #endif
0
4eff17414a43 nginx-0.0.1-2002-08-06-20:39:45 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff changeset
176 };
4eff17414a43 nginx-0.0.1-2002-08-06-20:39:45 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff changeset
177
4eff17414a43 nginx-0.0.1-2002-08-06-20:39:45 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff changeset
178
2806
a445bd4eb571 ngx_create_listening()
Igor Sysoev <igor@sysoev.ru>
parents: 2802
diff changeset
179 ngx_listening_t *ngx_create_listening(ngx_conf_t *cf, void *sockaddr,
a445bd4eb571 ngx_create_listening()
Igor Sysoev <igor@sysoev.ru>
parents: 2802
diff changeset
180 socklen_t socklen);
219
f57597ec5249 nginx-0.0.1-2004-01-06-19:49:34 import
Igor Sysoev <igor@sysoev.ru>
parents: 218
diff changeset
181 ngx_int_t ngx_set_inherited_sockets(ngx_cycle_t *cycle);
218
05592fd7a436 nginx-0.0.1-2004-01-05-23:55:48 import
Igor Sysoev <igor@sysoev.ru>
parents: 216
diff changeset
182 ngx_int_t ngx_open_listening_sockets(ngx_cycle_t *cycle);
2802
44b2081c015a use correct name
Igor Sysoev <igor@sysoev.ru>
parents: 2800
diff changeset
183 void ngx_configure_listening_sockets(ngx_cycle_t *cycle);
218
05592fd7a436 nginx-0.0.1-2004-01-05-23:55:48 import
Igor Sysoev <igor@sysoev.ru>
parents: 216
diff changeset
184 void ngx_close_listening_sockets(ngx_cycle_t *cycle);
417
0526206251f6 nginx-0.0.10-2004-09-07-19:29:22 import
Igor Sysoev <igor@sysoev.ru>
parents: 399
diff changeset
185 void ngx_close_connection(ngx_connection_t *c);
2854
d788477f5a67 ngx_connection_local_sockaddr()
Igor Sysoev <igor@sysoev.ru>
parents: 2806
diff changeset
186 ngx_int_t ngx_connection_local_sockaddr(ngx_connection_t *c, ngx_str_t *s,
d788477f5a67 ngx_connection_local_sockaddr()
Igor Sysoev <igor@sysoev.ru>
parents: 2806
diff changeset
187 ngx_uint_t port);
253
b6793bc5034b nginx-0.0.2-2004-02-09-10:46:43 import
Igor Sysoev <igor@sysoev.ru>
parents: 219
diff changeset
188 ngx_int_t ngx_connection_error(ngx_connection_t *c, ngx_err_t err, char *text);
218
05592fd7a436 nginx-0.0.1-2004-01-05-23:55:48 import
Igor Sysoev <igor@sysoev.ru>
parents: 216
diff changeset
189
543
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
190 ngx_connection_t *ngx_get_connection(ngx_socket_t s, ngx_log_t *log);
511a89da35ad nginx-0.2.0-RELEASE import
Igor Sysoev <igor@sysoev.ru>
parents: 539
diff changeset
191 void ngx_free_connection(ngx_connection_t *c);
91
637625a2acdb nginx-0.0.1-2003-05-19-20:39:14 import
Igor Sysoev <igor@sysoev.ru>
parents: 87
diff changeset
192
3880
e3cb8e27e413 reuse keepalive connections if there are no free worker connections
Igor Sysoev <igor@sysoev.ru>
parents: 3676
diff changeset
193 void ngx_reusable_connection(ngx_connection_t *c, ngx_uint_t reusable);
91
637625a2acdb nginx-0.0.1-2003-05-19-20:39:14 import
Igor Sysoev <igor@sysoev.ru>
parents: 87
diff changeset
194
0
4eff17414a43 nginx-0.0.1-2002-08-06-20:39:45 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff changeset
195 #endif /* _NGX_CONNECTION_H_INCLUDED_ */